summaryrefslogtreecommitdiffstats
path: root/src/plugins/platforms/qnx/qqnxintegration.h
diff options
context:
space:
mode:
authorFabian Bumberger <fbumberger@rim.com>2014-01-17 20:45:57 +0100
committerThe Qt Project <gerrit-noreply@qt-project.org>2014-01-28 19:32:53 +0100
commitb8103a4e8174446584caf80c0bf1a006b25d9905 (patch)
tree465a99e8d15a6037e48dccbb7a7aba5530b332ea /src/plugins/platforms/qnx/qqnxintegration.h
parenta4ff400e25c76a32ec8252285dda043f07b19c15 (diff)
[QNX] Introduce proper screen error handling
This patch adds a new function which does the error handling for libscreen calls. The patch introduces following changes: - Libscreen errors will not crash (qFatal)the application any more but rather post a warning message. -With the "flush-screen-context" option the screen_context is always flushed when a screen function is called. This enables better correlation between the time an error happens and the time it is logged. Change-Id: Ie2456e5b746dcf917d786f3b832847d2ebbe5f1e Reviewed-by: Kevin Krammer <kevin.krammer@kdab.com> Reviewed-by: Roger Maclean <rmaclean@qnx.com> Reviewed-by: Bernd Weimer <bweimer@blackberry.com> Reviewed-by: Rafael Roquetto <rafael.roquetto@kdab.com>
Diffstat (limited to 'src/plugins/platforms/qnx/qqnxintegration.h')
-rw-r--r--src/plugins/platforms/qnx/qqnxintegration.h10
1 files changed, 6 insertions, 4 deletions
diff --git a/src/plugins/platforms/qnx/qqnxintegration.h b/src/plugins/platforms/qnx/qqnxintegration.h
index 8b5614fe4f..b5f03d4727 100644
--- a/src/plugins/platforms/qnx/qqnxintegration.h
+++ b/src/plugins/platforms/qnx/qqnxintegration.h
@@ -85,7 +85,8 @@ public:
enum Option { // Options to be passed on command line.
NoOptions = 0x0,
FullScreenApplication = 0x1,
- RootWindow = 0x2
+ RootWindow = 0x2,
+ AlwaysFlushScreenContext = 0x4
};
Q_DECLARE_FLAGS(Options, Option)
explicit QQnxIntegration(const QStringList &paramList);
@@ -137,7 +138,8 @@ public:
void createDisplay(screen_display_t display, bool isPrimary);
void removeDisplay(QQnxScreen *screen);
QQnxScreen *primaryDisplay() const;
- Options options() const;
+ static Options options();
+ static screen_context_t screenContext();
private:
void createDisplays();
@@ -146,7 +148,7 @@ private:
static void addWindow(screen_window_t qnxWindow, QWindow *window);
static void removeWindow(screen_window_t qnxWindow);
- screen_context_t m_screenContext;
+ static screen_context_t ms_screenContext;
#if defined(QQNX_SCREENEVENTTHREAD)
QQnxScreenEventThread *m_screenEventThread;
#endif
@@ -176,7 +178,7 @@ private:
static QQnxWindowMapper ms_windowMapper;
static QMutex ms_windowMapperMutex;
- const Options m_options;
+ static Options ms_options;
friend class QQnxWindow;
};