11#if !__has_feature(objc_arc)
12#error This file must be compiled with Arc. Use -fobjc-arc flag
15#include "IPlugPlatformView.h"
20IPlatformView::IPlatformView(
bool opaque)
25IPlatformView::~IPlatformView()
30void* IPlatformView::CreatePlatformView(
void* pParent,
float x,
float y,
float w,
float h,
float scale)
33 PLATFORM_VIEW* platformView = [[PLATFORM_VIEW alloc] initWithFrame:MAKERECT(x,y,w,h)];
34 mPlatformView = (__bridge_retained
void*) platformView;
40void IPlatformView::RemovePlatformView()
43 PLATFORM_VIEW* platformView = (__bridge_transfer PLATFORM_VIEW*) mPlatformView;
44 [platformView removeFromSuperview];
47 mPlatformView =
nullptr;
50void IPlatformView::SetChildViewBounds(
float x,
float y,
float w,
float h,
float scale)
52 [(__bridge PLATFORM_VIEW*) mPlatformView setFrame: MAKERECT(x, y, w, h) ];
Common paths useful for plug-ins.