bugfix: X Window System error

the error was fixed by simply calling gdk_error_trap_push()

Change-Id: Iac365994024b84413222b81fb927f0c00713f6f5
This commit is contained in:
Hualet Wang 2015-09-07 15:30:41 +08:00
parent dac97f066d
commit 00c8423e49
Notes: Deepin Code Review 2016-06-14 07:19:47 +00:00
Verified+1: Anonymous Coward #1000004
Code-Review+2: <mr.asianwang@gmail.com>
Submitted-by: <mr.asianwang@gmail.com>
Submitted-at: Mon, 07 Sep 2015 15:36:47 +0800
Reviewed-on: https://cr.deepin.io/6819
Project: dde/dde-dock
Branch: refs/heads/master

View File

@ -16,6 +16,7 @@ AppIcon::AppIcon(QWidget *parent, Qt::WindowFlags f) :
// as far as I know, it's safe to call this method multiple times,
// because it does some check work internally.
gtk_init(NULL, NULL);
gdk_error_trap_push();
this->setAttribute(Qt::WA_TranslucentBackground);
this->setAlignment(Qt::AlignCenter);