예제 #1
0
    public Application()
    {
        Glade.XML gxml = new Glade.XML(null, "tiler.glade", null, null);
        gxml.Autoconnect(this);

        if (MainWindow == null || DrawingArea == null || AppBar == null)
        {
            throw new Exception("soem widgets not found");
        }

        DrawingArea.AddEvents((int)Gdk.EventMask.ButtonPressMask);
        DrawingArea.AddEvents((int)Gdk.EventMask.ButtonReleaseMask);
        DrawingArea.AddEvents((int)Gdk.EventMask.ButtonMotionMask);

        // libglade missed interactivity property :-/
        MainLayout.Remove(AppBar);
        AppBar = new AppBar(true, true, PreferencesType.Always);
        AppBar.UserResponse += new EventHandler(OnAppBarUserResponse);
        MainLayout.PackStart(AppBar, false, false, 0);
        AppBar.Show();

        TileGroupComboBox.Entry.Activated
            += new EventHandler(OnTileGroupComboBoxEntryActivated);

        MainWindow.Show();
    }
예제 #2
0
 static void userresponse_cb(IntPtr ab)
 {
     try {
         AppBar ab_managed = GLib.Object.GetObject(ab, false) as AppBar;
         ab_managed.OnUserResponse();
     } catch (Exception e) {
         GLib.ExceptionManager.RaiseUnhandledException(e, false);
     }
 }
예제 #3
0
 static void promptcleared_cb(IntPtr ab)
 {
     try {
         AppBar ab_managed = GLib.Object.GetObject(ab, false) as AppBar;
         ab_managed.OnPromptCleared();
     } catch (Exception e) {
         GLib.ExceptionManager.RaiseUnhandledException(e, false);
     }
 }
예제 #4
0
    public Application()
    {
        Glade.XML gxml = new Glade.XML(null, "tiler.glade", null, null);
        gxml.Autoconnect(this);

        if(MainWindow == null || DrawingArea == null || AppBar == null)
            throw new Exception("soem widgets not found");

        DrawingArea.AddEvents((int) Gdk.EventMask.ButtonPressMask);
        DrawingArea.AddEvents((int) Gdk.EventMask.ButtonReleaseMask);
        DrawingArea.AddEvents((int) Gdk.EventMask.ButtonMotionMask);

        // libglade missed interactivity property :-/
        MainLayout.Remove(AppBar);
        AppBar = new AppBar(true, true, PreferencesType.Always);
        AppBar.UserResponse += new EventHandler(OnAppBarUserResponse);
        MainLayout.PackStart(AppBar, false, false, 0);
        AppBar.Show();

        TileGroupComboBox.Entry.Activated
            += new EventHandler (OnTileGroupComboBoxEntryActivated);

        MainWindow.Show();
    }