[nanny] Add win32 help url laucher
- From: Roberto Majadas <telemaco src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [nanny] Add win32 help url laucher
- Date: Sat, 5 Feb 2011 12:22:36 +0000 (UTC)
commit e2e06afc18749674aaa23c7586447d5ea5e56142
Author: Roberto Majadas <roberto majadas openshine com>
Date: Sat Feb 5 13:21:26 2011 +0100
Add win32 help url laucher
client/gnome/admin/src/AdminConsole.py | 17 ++++++++++++-----
1 files changed, 12 insertions(+), 5 deletions(-)
---
diff --git a/client/gnome/admin/src/AdminConsole.py b/client/gnome/admin/src/AdminConsole.py
index ded9d1b..9186161 100644
--- a/client/gnome/admin/src/AdminConsole.py
+++ b/client/gnome/admin/src/AdminConsole.py
@@ -26,6 +26,9 @@
import os
if os.name == "posix":
import dbus
+elif os.name == "nt":
+ import win32api
+ import win32con
import gtk
import pango
@@ -420,11 +423,15 @@ class AdminConsole:
self.im_hoursday_spinbutton.set_sensitive (False)
def __on_help_button_clicked (self, widget, data=None):
- try:
- gtk.show_uri(None , "ghelp:nanny", gtk.get_current_event_time())
- except:
- os.system("yelp ghelp:nanny")
-
+ if os.name == "posix":
+ try:
+ gtk.show_uri(None , "ghelp:nanny", gtk.get_current_event_time())
+ except:
+ os.system("yelp ghelp:nanny")
+ elif os.name == "nt":
+ win32api.ShellExecute(None, "open",
+ "http://library.gnome.org/users/nanny/stable/",
+ None, None, win32con.SW_SHOWNORMAL)
def __on_unlock_button_clicked (self, widget, data=None):
self.dbus_client.unlock()
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]