- Timestamp:
- Jan 14, 2018, 10:48:21 PM (7 years ago)
- Location:
- trunk
- Files:
-
- 4 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/Languages/OpenTaskManager.cs.po
r2 r3 13 13 14 14 #: tformmain.aalwaysontop.caption 15 #, fuzzy16 15 msgctxt "tformmain.aalwaysontop.caption" 17 16 msgid "Always on top" … … 27 26 28 27 #: tformmain.arun.caption 29 #, fuzzy30 28 msgctxt "tformmain.arun.caption" 31 29 msgid "Run new task" 32 30 msgstr "Spustit novou úlohu" 33 31 32 #: tformmain.aservicerestart.caption 33 msgctxt "tformmain.aservicerestart.caption" 34 msgid "Restart" 35 msgstr "Restartovat" 36 37 #: tformmain.aservicestart.caption 38 msgid "Start" 39 msgstr "Spustit" 40 41 #: tformmain.aservicestop.caption 42 msgctxt "tformmain.aservicestop.caption" 43 msgid "Stop" 44 msgstr "Zastavit" 45 34 46 #: tformmain.caption 35 47 msgid "Open Task Manager" … … 37 49 38 50 #: tformmain.listviewdetails.columns[0].caption 39 #, fuzzy40 51 msgctxt "tformmain.listviewdetails.columns[0].caption" 41 52 msgid "Name" … … 57 68 58 69 #: tformmain.listviewdetails.columns[4].caption 59 #, fuzzy60 70 msgctxt "tformmain.listviewdetails.columns[4].caption" 61 71 msgid "Processor" … … 63 73 64 74 #: tformmain.listviewdetails.columns[5].caption 65 #, fuzzy66 75 msgctxt "tformmain.listviewdetails.columns[5].caption" 67 76 msgid "Memory" … … 74 83 75 84 #: tformmain.listviewonstartup.columns[0].caption 76 #, fuzzy77 85 msgctxt "tformmain.listviewonstartup.columns[0].caption" 78 86 msgid "Name" … … 93 101 94 102 #: tformmain.listviewprocesses.columns[0].caption 95 #, fuzzy96 103 msgctxt "tformmain.listviewprocesses.columns[0].caption" 97 104 msgid "Name" … … 99 106 100 107 #: tformmain.listviewprocesses.columns[1].caption 101 #, fuzzy102 108 msgctxt "tformmain.listviewprocesses.columns[1].caption" 103 109 msgid "Processor" … … 105 111 106 112 #: tformmain.listviewprocesses.columns[2].caption 107 #, fuzzy108 113 msgctxt "tformmain.listviewprocesses.columns[2].caption" 109 114 msgid "Memory" … … 111 116 112 117 #: tformmain.listviewprocesses.columns[3].caption 113 #, fuzzy114 118 msgctxt "tformmain.listviewprocesses.columns[3].caption" 115 119 msgid "Drive" … … 117 121 118 122 #: tformmain.listviewprocesses.columns[4].caption 119 #, fuzzy120 123 msgctxt "tformmain.listviewprocesses.columns[4].caption" 121 124 msgid "Network" … … 123 126 124 127 #: tformmain.listviewservices.columns[0].caption 125 #, fuzzy126 128 msgctxt "tformmain.listviewservices.columns[0].caption" 127 129 msgid "Name" … … 174 176 175 177 #: tformmain.menuitem19.caption 176 #, fuzzy177 178 msgctxt "tformmain.menuitem19.caption" 178 179 msgid "High" … … 188 189 189 190 #: tformmain.menuitem21.caption 190 #, fuzzy191 191 msgctxt "tformmain.menuitem21.caption" 192 192 msgid "Normal" … … 198 198 199 199 #: tformmain.menuitem23.caption 200 #, fuzzy201 200 msgctxt "tformmain.menuitem23.caption" 202 201 msgid "Low" … … 240 239 241 240 #: tformmain.menuitem33.caption 241 msgctxt "tformmain.menuitem33.caption" 242 242 msgid "Restart" 243 243 msgstr "Restartovat" … … 253 253 254 254 #: tformmain.menuitem37.caption 255 msgctxt "tformmain.menuitem37.caption" 255 256 msgid "Go to details" 256 257 msgstr "Přejít na detaily" … … 274 275 msgstr "Vlastnosti" 275 276 277 #: tformmain.menuitem45.caption 278 msgid "Open Services window" 279 msgstr "Otevřít okno Služby" 280 281 #: tformmain.menuitem46.caption 282 msgctxt "tformmain.menuitem46.caption" 283 msgid "Search online" 284 msgstr "Hledat online" 285 286 #: tformmain.menuitem47.caption 287 msgctxt "tformmain.menuitem47.caption" 288 msgid "Go to details" 289 msgstr "Přejít na detaily" 290 276 291 #: tformmain.menuitem5.caption 277 292 msgid "Minimalize on use" … … 324 339 325 340 #: uformmain.srunnewtask 326 #, fuzzy327 341 msgctxt "uformmain.srunnewtask" 328 342 msgid "Run new task" -
trunk/Languages/OpenTaskManager.po
r2 r3 20 20 msgstr "" 21 21 22 #: tformmain.aservicerestart.caption 23 msgctxt "tformmain.aservicerestart.caption" 24 msgid "Restart" 25 msgstr "" 26 27 #: tformmain.aservicestart.caption 28 msgid "Start" 29 msgstr "" 30 31 #: tformmain.aservicestop.caption 32 msgctxt "tformmain.aservicestop.caption" 33 msgid "Stop" 34 msgstr "" 35 22 36 #: tformmain.caption 23 37 msgid "Open Task Manager" … … 215 229 216 230 #: tformmain.menuitem33.caption 231 msgctxt "tformmain.menuitem33.caption" 217 232 msgid "Restart" 218 233 msgstr "" … … 228 243 229 244 #: tformmain.menuitem37.caption 245 msgctxt "tformmain.menuitem37.caption" 230 246 msgid "Go to details" 231 247 msgstr "" … … 249 265 msgstr "" 250 266 267 #: tformmain.menuitem45.caption 268 msgid "Open Services window" 269 msgstr "" 270 271 #: tformmain.menuitem46.caption 272 msgctxt "tformmain.menuitem46.caption" 273 msgid "Search online" 274 msgstr "" 275 276 #: tformmain.menuitem47.caption 277 msgctxt "tformmain.menuitem47.caption" 278 msgid "Go to details" 279 msgstr "" 280 251 281 #: tformmain.menuitem5.caption 252 282 msgid "Minimalize on use" -
trunk/UFormMain.lfm
r2 r3 20 20 ActivePage = TabSheetServices 21 21 Align = alClient 22 PopupMenu = PopupMenuServices 22 23 TabIndex = 6 23 24 TabOrder = 0 … … 269 270 OnExecute = ARestoreExecute 270 271 Visible = False 272 end 273 object AServiceStop: TAction 274 Caption = 'Stop' 275 OnExecute = AServiceStopExecute 276 end 277 object AServiceRestart: TAction 278 Caption = 'Restart' 279 OnExecute = AServiceRestartExecute 280 end 281 object AServiceStart: TAction 282 Caption = 'Start' 283 OnExecute = AServiceStartExecute 271 284 end 272 285 end … … 4670 4683 end 4671 4684 end 4685 object PopupMenuServices: TPopupMenu 4686 OnPopup = PopupMenuServicesPopup 4687 left = 712 4688 top = 104 4689 object MenuItem41: TMenuItem 4690 Action = AServiceStart 4691 end 4692 object MenuItem42: TMenuItem 4693 Action = AServiceStop 4694 end 4695 object MenuItem43: TMenuItem 4696 Action = AServiceRestart 4697 end 4698 object MenuItem44: TMenuItem 4699 Caption = '-' 4700 end 4701 object MenuItem45: TMenuItem 4702 Caption = 'Open Services window' 4703 end 4704 object MenuItem46: TMenuItem 4705 Caption = 'Search online' 4706 end 4707 object MenuItem47: TMenuItem 4708 Caption = 'Go to details' 4709 end 4710 end 4672 4711 end -
trunk/UFormMain.pas
r2 r3 41 41 TFormMain = class(TForm) 42 42 AAlwaysOnTop: TAction; 43 AServiceStart: TAction; 44 AServiceRestart: TAction; 45 AServiceStop: TAction; 43 46 ARestore: TAction; 44 47 ARun: TAction; … … 86 89 MenuItem4: TMenuItem; 87 90 MenuItem40: TMenuItem; 91 MenuItem41: TMenuItem; 92 MenuItem42: TMenuItem; 93 MenuItem43: TMenuItem; 94 MenuItem44: TMenuItem; 95 MenuItem45: TMenuItem; 96 MenuItem46: TMenuItem; 97 MenuItem47: TMenuItem; 88 98 MenuItem5: TMenuItem; 89 99 MenuItem6: TMenuItem; … … 95 105 PageControl1: TPageControl; 96 106 Panel1: TPanel; 107 PopupMenuServices: TPopupMenu; 97 108 PopupMenuProcesses: TPopupMenu; 98 109 PopupMenuDetails: TPopupMenu; … … 110 121 procedure ARestoreExecute(Sender: TObject); 111 122 procedure ARunExecute(Sender: TObject); 123 procedure AServiceRestartExecute(Sender: TObject); 124 procedure AServiceStartExecute(Sender: TObject); 125 procedure AServiceStopExecute(Sender: TObject); 112 126 procedure FormCreate(Sender: TObject); 113 127 procedure FormDestroy(Sender: TObject); … … 118 132 procedure ListViewServicesData(Sender: TObject; Item: TListItem); 119 133 procedure PageControl1Change(Sender: TObject); 134 procedure PopupMenuServicesPopup(Sender: TObject); 120 135 procedure TimerRefreshTimer(Sender: TObject); 121 136 procedure TrayIcon1Click(Sender: TObject); … … 144 159 145 160 var 146 SystemServiceStatusText: array [TSystemServiceState] of string = (' Running', 'Stopped');161 SystemServiceStatusText: array [TSystemServiceState] of string = ('Stopped', 'Running'); 147 162 { TFormMain } 148 163 … … 176 191 end; 177 192 193 procedure TFormMain.AServiceRestartExecute(Sender: TObject); 194 begin 195 if Assigned(ListViewServices.Selected) then begin 196 ExecuteAnWaitForOutput('/bin/systemctl', ['restart', 197 TSystemService(ListViewServices.Selected.Data).Name]) 198 end; 199 end; 200 201 procedure TFormMain.AServiceStartExecute(Sender: TObject); 202 begin 203 ExecuteAnWaitForOutput('/bin/systemctl', ['start', 204 TSystemService(ListViewServices.Selected.Data).Name]) 205 end; 206 207 procedure TFormMain.AServiceStopExecute(Sender: TObject); 208 begin 209 ExecuteAnWaitForOutput('/bin/systemctl', ['stop', 210 TSystemService(ListViewServices.Selected.Data).Name]) 211 end; 212 178 213 procedure TFormMain.FormCreate(Sender: TObject); 179 214 begin … … 204 239 if Item.Index < Processes.Count then 205 240 with TSystemProcess(Processes[Item.Index]) do begin 241 Item.Data := Processes[Item.Index]; 206 242 Item.Caption := Name; 207 243 Item.SubItems.Add(IntToStr(PID)); … … 218 254 if Item.Index < Processes.Count then 219 255 with TSystemProcess(Processes[Item.Index]) do begin 256 Item.Data := Processes[Item.Index]; 220 257 Item.Caption := Name; 221 258 Item.SubItems.Add(FloatToStr(Cpu)); … … 230 267 if Item.Index < Services.Count then 231 268 with TSystemService(Services[Item.Index]) do begin 269 Item.Data := Services[Item.Index]; 232 270 Item.Caption := Name; 233 271 Item.SubItems.Add(''); … … 241 279 begin 242 280 ReloadTab; 281 end; 282 283 procedure TFormMain.PopupMenuServicesPopup(Sender: TObject); 284 begin 285 AServiceRestart.Enabled := Assigned(ListViewServices.Selected) and 286 (TSystemService(ListViewServices.Selected.Data).State = ssRunning); 287 AServiceStop.Enabled := Assigned(ListViewServices.Selected) and 288 (TSystemService(ListViewServices.Selected.Data).State = ssRunning); 289 AServiceStart.Enabled := Assigned(ListViewServices.Selected) and 290 (TSystemService(ListViewServices.Selected.Data).State = ssStopped); 243 291 end; 244 292
Note:
See TracChangeset
for help on using the changeset viewer.