summaryrefslogtreecommitdiff
path: root/vcl
diff options
context:
space:
mode:
authorDavid Tardon <dtardon@redhat.com>2014-08-19 15:22:45 +0200
committerDavid Tardon <dtardon@redhat.com>2014-08-19 15:22:45 +0200
commitca54b6ea903da7a1bc815c27389d2f1d362edaff (patch)
treebda47339d43acbbd4640d9432b3ed27ed394ab0b /vcl
parent4b4bff34027cca49fd13e82d33d1b399848838fa (diff)
use SolarMutex instead of a custom GdkThreadLock
C.f. commit 861a1c2dea41c141bffce54c30d53e65b7b88973. Change-Id: I9f6cf917c63ee8c0db5461529c4ee277e231368f
Diffstat (limited to 'vcl')
-rw-r--r--vcl/unx/gtk/fpicker/SalGtkPicker.cxx2
-rw-r--r--vcl/unx/gtk/fpicker/SalGtkPicker.hxx7
-rw-r--r--vcl/unx/gtk/window/gtksalmenu.cxx9
3 files changed, 2 insertions, 16 deletions
diff --git a/vcl/unx/gtk/fpicker/SalGtkPicker.cxx b/vcl/unx/gtk/fpicker/SalGtkPicker.cxx
index 25553aa6ad3b..ccae7d181a80 100644
--- a/vcl/unx/gtk/fpicker/SalGtkPicker.cxx
+++ b/vcl/unx/gtk/fpicker/SalGtkPicker.cxx
@@ -98,7 +98,7 @@ extern "C"
{
static gboolean canceldialog(RunDialog *pDialog)
{
- GdkThreadLock lock;
+ SolarMutexGuard g;
pDialog->cancel();
return false;
}
diff --git a/vcl/unx/gtk/fpicker/SalGtkPicker.hxx b/vcl/unx/gtk/fpicker/SalGtkPicker.hxx
index 6a72e7f61b01..8f4552c03818 100644
--- a/vcl/unx/gtk/fpicker/SalGtkPicker.hxx
+++ b/vcl/unx/gtk/fpicker/SalGtkPicker.hxx
@@ -66,13 +66,6 @@ class SalGtkPicker
OUString getResString( sal_Int32 aId );
};
-class GdkThreadLock
-{
-public:
- GdkThreadLock() { gdk_threads_enter(); }
- ~GdkThreadLock() { gdk_threads_leave(); }
-};
-
//Run the Gtk Dialog. Watch for any "new windows" created while we're
//executing and consider that a CANCEL event to avoid e.g. "file cannot be opened"
//modal dialogs and this one getting locked if some other API call causes this
diff --git a/vcl/unx/gtk/window/gtksalmenu.cxx b/vcl/unx/gtk/window/gtksalmenu.cxx
index 92176b7467fc..09cd44f150d7 100644
--- a/vcl/unx/gtk/window/gtksalmenu.cxx
+++ b/vcl/unx/gtk/window/gtksalmenu.cxx
@@ -450,17 +450,10 @@ void GtkSalMenu::SetSubMenu( SalMenuItem* pSalMenuItem, SalMenu* pSubMenu, unsig
pItem->mpSubMenu = pGtkSubMenu;
}
-class GdkThreadLock
-{
-public:
- GdkThreadLock() { gdk_threads_enter(); }
- ~GdkThreadLock() { gdk_threads_leave(); }
-};
-
static bool bInvalidMenus = false;
static gboolean RefreshMenusUnity(gpointer)
{
- GdkThreadLock aLock;
+ SolarMutexGuard g;
SalDisplay* pSalDisplay = GetGenericData()->GetSalDisplay();
std::list< SalFrame* >::const_iterator pSalFrame = pSalDisplay->getFrames().begin();