summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--ldmicro/ldmicro.cpp11
1 files changed, 11 insertions, 0 deletions
diff --git a/ldmicro/ldmicro.cpp b/ldmicro/ldmicro.cpp
index be02fd5..ea4e1f0 100644
--- a/ldmicro/ldmicro.cpp
+++ b/ldmicro/ldmicro.cpp
@@ -719,6 +719,17 @@ gboolean LD_GTK_mouse_click_hook(GtkWidget *widget, GdkEvent *event, gpointer us
* WM_LBUTTONDBLCLK, WM_LBUTTONDOWN
*/
+ RECT Rect;
+ GetWindowRect(ScrollWindow, &Rect);
+ int wy;
+ gtk_window_get_position(GTK_WINDOW(MainWindow), NULL, &wy);
+
+ // g_print("net: %i\n", wy + 30 + Rect.bottom);
+
+ /// Identify if mouse is clicked outside drawing area
+ if (wy + 30 + Rect.bottom < event->button.y_root)
+ return FALSE;
+
GtkAdjustment *adjustment = gtk_scrolled_window_get_vadjustment(GTK_SCROLLED_WINDOW(ScrollWindow));
switch(event->button.type)