int AdBannerSetLocation(int location);
Sets the location of the iAd.
Return Value
Returns non-zero if successful, zero if unsuccessful or if iAds are not supported on the device.
Parameters
location Specifies where the iAd should be displayed. Possible values are:
Remarks
AdBannerSetLocation() sets the location of the previously added iAd banner.
NOTE: If no iAd banner has yet been initialized, this function will have no effect.
Availability
Available in DragonFireSDK 1.4 and later on devices running iOS 4.0 or later.
Example
#include "DragonFireSDK.h"
int HideButton; int MoveButton;
int BannerLocation=0; int BannerVisible=1;
int OnButton(int value) { switch (value) { case 1: if (BannerVisible) BannerVisible = 0; else BannerVisible = 1; AdBannerSetVisible(BannerVisible); break; case 2: if (BannerLocation) BannerLocation = 0; else BannerLocation = 1; AdBannerSetLocation(BannerLocation); break; default: break; } return(1); }
void AppMain() { HideButton = ButtonAdd("Images/Hide", 10, 100, OnButton, 1); MoveButton = ButtonAdd("Images/Move", 10, 150, OnButton, 2); AdBannerInit(BannerLocation); }
void OnTimer() {
}
void AppExit() {
} |