28 pyqtApi = 2 |
28 pyqtApi = 2 |
29 # End-Of-Header |
29 # End-Of-Header |
30 |
30 |
31 error = "" |
31 error = "" |
32 |
32 |
|
33 |
33 def previewPix(): |
34 def previewPix(): |
34 """ |
35 """ |
35 Module function to return a preview pixmap. |
36 Module function to return a preview pixmap. |
36 |
37 |
37 @return preview pixmap (QPixmap) |
38 @return preview pixmap (QPixmap) |
38 """ |
39 """ |
39 fname = os.path.join(os.path.dirname(__file__), |
40 fname = os.path.join(os.path.dirname(__file__), |
40 "ViewManagerPlugins", "Tabview", "preview.png") |
41 "ViewManagerPlugins", "Tabview", "preview.png") |
41 return QPixmap(fname) |
42 return QPixmap(fname) |
42 |
43 |
|
44 |
43 class VmTabviewPlugin(QObject): |
45 class VmTabviewPlugin(QObject): |
44 """ |
46 """ |
45 Class implementing the Tabview view manager plugin. |
47 Class implementing the Tabview view manager plugin. |
46 """ |
48 """ |
47 def __init__(self, ui): |
49 def __init__(self, ui): |
55 |
57 |
56 def activate(self): |
58 def activate(self): |
57 """ |
59 """ |
58 Public method to activate this plugin. |
60 Public method to activate this plugin. |
59 |
61 |
60 @return tuple of reference to instantiated viewmanager and |
62 @return tuple of reference to instantiated viewmanager and |
61 activation status (boolean) |
63 activation status (boolean) |
62 """ |
64 """ |
63 from ViewManagerPlugins.Tabview.Tabview import Tabview |
65 from ViewManagerPlugins.Tabview.Tabview import Tabview |
64 self.__object = Tabview(self.__ui) |
66 self.__object = Tabview(self.__ui) |
65 return self.__object, True |
67 return self.__object, True |