index 84e69ee24317ce606a9f55409caba497042c5de1..7cb360a43c24297a3f41f54dc36bcc4772228f70 100644 (file)
--- a/src/ui/dialog/dialog.cpp
+++ b/src/ui/dialog/dialog.cpp
# include <config.h>
#endif
-#include <typeinfo>
#include <gtkmm/stock.h>
#include <gtk/gtk.h>
// g_print ("read %d %d %d %d\n", x, y, w, h);
+ if (x<0) x=0;
+ if (y<0) y=0;
+
// If there are stored height and width values for the dialog,
// resize the window to match; otherwise we leave it at its default
if (w != 0 && h != 0) {
void hideCallback(GtkObject *object, gpointer dlgPtr)
{
- Dialog* example;
- if ((void*)dlgPtr == 0 || typeid(dlgPtr) != typeid(example))
- return;
+ g_return_if_fail( dlgPtr != NULL );
Dialog *dlg = (Dialog *)dlgPtr;
dlg->onHideF12();
void unhideCallback(GtkObject *object, gpointer dlgPtr)
{
- Dialog* example;
- if ((void*)dlgPtr == 0 || typeid(dlgPtr) != typeid(example))
- return;
+ g_return_if_fail( dlgPtr != NULL );
Dialog *dlg = (Dialog *)dlgPtr;
dlg->onShowF12();