iOS: implement QIOSWindow::winId()
Change-Id: I3dd7accae43bcf7d4d6dfd8b272ab65d67bd935c Reviewed-by: Tor Arne Vestbø <tor.arne.vestbo@digia.com>
This commit is contained in:
parent
15bdf85f28
commit
4993d3ed6b
@ -160,7 +160,8 @@ GLuint QIOSContext::defaultFramebufferObject(QPlatformSurface *surface) const
|
||||
framebufferObject.renderbufferHeight != platformWindow->effectiveHeight()) {
|
||||
|
||||
glBindRenderbuffer(GL_RENDERBUFFER, framebufferObject.colorRenderbuffer);
|
||||
CAEAGLLayer *layer = static_cast<CAEAGLLayer *>(platformWindow->nativeView().layer);
|
||||
UIView *view = reinterpret_cast<UIView *>(platformWindow->winId());
|
||||
CAEAGLLayer *layer = static_cast<CAEAGLLayer *>(view.layer);
|
||||
[m_eaglContext renderbufferStorage:GL_RENDERBUFFER fromDrawable:layer];
|
||||
|
||||
glGetRenderbufferParameteriv(GL_RENDERBUFFER, GL_RENDERBUFFER_WIDTH, &framebufferObject.renderbufferWidth);
|
||||
|
@ -158,7 +158,7 @@ void *QIOSIntegration::nativeResourceForWindow(const QByteArray &resource, QWind
|
||||
QIOSWindow *platformWindow = static_cast<QIOSWindow *>(window->handle());
|
||||
|
||||
if (lowerCaseResource == "uiview")
|
||||
return platformWindow->nativeView();
|
||||
return reinterpret_cast<void *>(platformWindow->winId());
|
||||
|
||||
return 0;
|
||||
}
|
||||
|
@ -76,7 +76,7 @@ public:
|
||||
int effectiveWidth() const;
|
||||
int effectiveHeight() const;
|
||||
|
||||
UIView *nativeView() const { return m_view; }
|
||||
WId winId() const { return WId(m_view); };
|
||||
|
||||
QList<QWindowSystemInterface::TouchPoint> &touchPoints() { return m_touchPoints; }
|
||||
QHash<UITouch *, int> &activeTouches() { return m_activeTouches; }
|
||||
|
Loading…
Reference in New Issue
Block a user