Exemplo n.º 1
0
        void HandleIconSelected(object o, IconSelectedArgs args)
        {
            CurrentlySelected = userData [args.Num];

            if (IconSelected != null)
                IconSelected (this, EventArgs.Empty);

            if (args.Event != null && args.Event.Type == Gdk.EventType.TwoButtonPress)
                if (IconDoubleClicked != null)
                    IconDoubleClicked (this, EventArgs.Empty);
        }
Exemplo n.º 2
0
 // Enables the OK button
 private void OnIconSelectedProject(object o, IconSelectedArgs args)
 {
     try
     {
         switch (args.Num)
         {
             case 0:
                 _selection = ProjectDialogAction.New;
                 break;
             case 1:
                 _selection = ProjectDialogAction.Open;
                 break;
             case 2:
                 _selection = ProjectDialogAction.ImportXmi;
                 break;
             case 3:
                 _selection = ProjectDialogAction.ReverseEngineering;
                 break;
             default:
                 _selection = ProjectDialogAction.None;
                 break;
         }
         _buttonOK.Sensitive = (args.Num >= 0);
     }
     catch (Exception ex) { }
 }