~ubuntu-branches/ubuntu/trusty/monodevelop/trusty-proposed

« back to all changes in this revision

Viewing changes to src/core/MonoDevelop.Ide/MonoDevelop.Ide.Commands/HelpCommands.cs

  • Committer: Package Import Robot
  • Author(s): Jo Shields
  • Date: 2013-05-12 09:46:03 UTC
  • mto: This revision was merged to the branch mainline in revision 29.
  • Revision ID: package-import@ubuntu.com-20130512094603-mad323bzcxvmcam0
Tags: upstream-4.0.5+dfsg
ImportĀ upstreamĀ versionĀ 4.0.5+dfsg

Show diffs side-by-side

added added

removed removed

Lines of Context:
26
26
//
27
27
 
28
28
 
 
29
using System;
29
30
using MonoDevelop.Ide.Gui.Dialogs;
30
31
using MonoDevelop.Ide.Gui;
31
32
using MonoDevelop.Components.Commands;
38
39
        public enum HelpCommands {
39
40
                Help,
40
41
                TipOfTheDay,
 
42
                OpenLogDirectory,
41
43
                About
42
44
        }
43
45
 
56
58
                }
57
59
        }
58
60
 
 
61
        // MonoDevelop.Ide.Commands.HelpCommands.OpenLogDirectory
 
62
        public class OpenLogDirectoryHandler : CommandHandler
 
63
        {
 
64
                protected override void Run ()
 
65
                {
 
66
                        try {
 
67
                                var profile = MonoDevelop.Core.UserProfile.Current;
 
68
                                if (profile != null && System.IO.Directory.Exists (profile.LogDir))
 
69
                                        System.Diagnostics.Process.Start (profile.LogDir);
 
70
                        } catch (Exception ex) {
 
71
                                MonoDevelop.Core.LoggingService.LogError ("Could not open the Log Directory", ex);
 
72
                        }
 
73
                }
 
74
        }
 
75
 
59
76
        // MonoDevelop.Ide.Commands.HelpCommands.TipOfTheDay
60
77
        public class TipOfTheDayHandler : CommandHandler
61
78
        {
81
98
                {
82
99
                        FeedbackService.ShowFeedbackWindow ();
83
100
                }
 
101
 
 
102
                protected override void Update (CommandInfo info)
 
103
                {
 
104
                        info.Visible = FeedbackService.Enabled;
 
105
                }
84
106
        }
85
107
}