Skip to content

Popup-window style view for Objective-C, which loads contents of an HTML file. Easy one-line usage. Check the readme for example

Notifications You must be signed in to change notification settings

icanzilb/MTPopupWindow

Repository files navigation

MTPopupWindow

MTPopupWindow is an Objective-C class, which allows the programmer to show a popup style window within an iOS application. The class uses Quartz2D to draw the popup and the buttons needed for the UI, so it is fully compatible with Auto Layout.

This class requires iOS6+ as it uses layout constraints.

The popup window is useful to show terms&conditions, about screens, or embeded web pages within an app. The popup is designed to show HTML content - from a local for the app html file (+ local images) or a remote HTML web page.

GitHub Logo GitHub Logo

MTPopupWindow announce post + source code examples:

http://touch-code-magazine.com/showing-a-popup-window-in-ios6-modernized-tutorial-code-download/

Code samples:

Short source code example:

#import "MTPopupWindow.h"
...
[MTPopupWindow showWindowWithHTMLFile:@"info.html"];

This 1-liner will load the info.html from the app Resources directory and show it in a popup window maximized in the app window.

To specify in which view the popup window should appear, use this code:

#import "MTPopupWindow.h"
...
MTPopupWindow* winPop = [[MTPopupWindow alloc] init];
winPop.fileName = @"info.html";
[winPop showInView:self.view];

About

Popup-window style view for Objective-C, which loads contents of an HTML file. Easy one-line usage. Check the readme for example

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published