OSDN Git Service

WinGui:
[handbrake-jp/handbrake-jp-git.git] / win / C# / HandBrake.ApplicationServices / Init.cs
1 /*  Init.cs $\r
2     This file is part of the HandBrake source code.\r
3     Homepage: <http://handbrake.fr>.\r
4     It may be used under the terms of the GNU General Public License. */\r
5 \r
6 namespace HandBrake.ApplicationServices\r
7 {\r
8     using System;\r
9     using System.Reflection;\r
10 \r
11     /// <summary>\r
12     /// Initialize ApplicationServices\r
13     /// </summary>\r
14     public class Init\r
15     {\r
16         /// <summary>\r
17         /// Setup the Settings used by the applicaiton with this library\r
18         /// </summary>\r
19         /// <param name="versionString">\r
20         /// The version / name of the application that's using this DLL.\r
21         /// </param>\r
22         /// <param name="instanceId">\r
23         /// The Instance ID\r
24         /// </param>\r
25         /// <param name="completionOption">\r
26         /// The completion option.\r
27         /// </param>\r
28         /// <param name="disableDvdNav">\r
29         /// The disable dvd nav.\r
30         /// </param>\r
31         /// <param name="growlEncode">\r
32         /// The growl encode.\r
33         /// </param>\r
34         /// <param name="growlQueue">\r
35         /// The growl queue.\r
36         /// </param>\r
37         /// <param name="processPriority">\r
38         /// The process priority.\r
39         /// </param>\r
40         /// <param name="saveLogPath">\r
41         /// The save log path.\r
42         /// </param>\r
43         /// <param name="saveLogToSpecifiedPath">\r
44         /// The save log to specified path.\r
45         /// </param>\r
46         /// <param name="saveLogWithVideo">\r
47         /// The save log with video.\r
48         /// </param>\r
49         /// <param name="showCliForInGuiEncodeStatus">\r
50         /// The show cli for in gui encode status.\r
51         /// </param>\r
52         /// <param name="preventSleep">\r
53         /// Prevent the system from sleeping\r
54         /// </param>\r
55         public static void SetupSettings(string versionString, int instanceId, string completionOption, bool disableDvdNav,\r
56                                   bool growlEncode, bool growlQueue, string processPriority, string saveLogPath, bool saveLogToSpecifiedPath,\r
57                                   bool saveLogWithVideo, bool showCliForInGuiEncodeStatus, bool preventSleep)\r
58         {\r
59             InstanceId = instanceId;\r
60             HandBrakeGuiVersionString = versionString;\r
61             CompletionOption = completionOption;\r
62             DisableDvdNav = disableDvdNav;\r
63             GrowlEncode = growlEncode;\r
64             GrowlQueue = growlQueue;\r
65             ProcessPriority = processPriority;\r
66             SaveLogPath = saveLogPath;\r
67             SaveLogToSpecifiedPath = saveLogToSpecifiedPath;\r
68             SaveLogWithVideo = saveLogWithVideo;\r
69             ShowCliForInGuiEncodeStatus = showCliForInGuiEncodeStatus;\r
70             PreventSleep = preventSleep;\r
71         }\r
72 \r
73         /// <summary>\r
74         /// Gets the Assembly version.\r
75         /// </summary>\r
76         /// <returns>\r
77         /// Version data\r
78         /// </returns>\r
79         public static Version AssemblyVersion()\r
80         {\r
81             return Assembly.GetExecutingAssembly().GetName().Version;\r
82         }\r
83 \r
84         /// <summary>\r
85         /// The instance ID used by the Main Applicaiton\r
86         /// </summary>\r
87         public static int InstanceId;\r
88 \r
89         /// <summary>\r
90         /// The Applicaiton that uses this DLL can pass in it's version string.\r
91         /// </summary>\r
92         public static string HandBrakeGuiVersionString;\r
93 \r
94         /// <summary>\r
95         /// What to do when the encode completes.\r
96         /// </summary>\r
97         public static string CompletionOption;\r
98 \r
99         /// <summary>\r
100         /// Disable LibDvdNav\r
101         /// </summary>\r
102         public static bool DisableDvdNav;\r
103 \r
104         /// <summary>\r
105         /// Growl when an encode has finished.\r
106         /// </summary>\r
107         public static bool GrowlEncode;\r
108 \r
109         /// <summary>\r
110         /// Growl when a queue has finished.\r
111         /// </summary>\r
112         public static bool GrowlQueue;\r
113 \r
114         /// <summary>\r
115         /// The Process Priority for HandBrakeCLI\r
116         /// </summary>\r
117         public static string ProcessPriority;\r
118 \r
119         /// <summary>\r
120         /// Path to save log files to.\r
121         /// </summary>\r
122         public static string SaveLogPath;\r
123 \r
124         /// <summary>\r
125         /// Copy log files to the SaveLogPath\r
126         /// </summary>\r
127         public static bool SaveLogToSpecifiedPath;\r
128 \r
129         /// <summary>\r
130         /// Save a copy of the log files with the video\r
131         /// </summary>\r
132         public static bool SaveLogWithVideo;\r
133 \r
134         /// <summary>\r
135         /// Show the CLI window when encoding.\r
136         /// </summary>\r
137         public static bool ShowCliForInGuiEncodeStatus;\r
138 \r
139         /// <summary>\r
140         /// Prevent system sleep\r
141         /// </summary>\r
142         public static bool PreventSleep;\r
143     }\r
144 }\r