13 from PyQt4.QtCore import * |
13 from PyQt4.QtCore import * |
14 from PyQt4.QtGui import * |
14 from PyQt4.QtGui import * |
15 |
15 |
16 from UI.Browser import Browser |
16 from UI.Browser import Browser |
17 |
17 |
18 from E4Gui.E4TabWidget import E4TabWidget |
18 from E5Gui.E5TabWidget import E5TabWidget |
19 from E4Gui.E4Led import E4Led |
19 from E5Gui.E5Led import E5Led |
20 |
20 |
21 from .ProjectSourcesBrowser import ProjectSourcesBrowser |
21 from .ProjectSourcesBrowser import ProjectSourcesBrowser |
22 from .ProjectFormsBrowser import ProjectFormsBrowser |
22 from .ProjectFormsBrowser import ProjectFormsBrowser |
23 from .ProjectTranslationsBrowser import ProjectTranslationsBrowser |
23 from .ProjectTranslationsBrowser import ProjectTranslationsBrowser |
24 from .ProjectResourcesBrowser import ProjectResourcesBrowser |
24 from .ProjectResourcesBrowser import ProjectResourcesBrowser |
30 |
30 |
31 from .ProjectBrowserFlags import SourcesBrowserFlag, FormsBrowserFlag, \ |
31 from .ProjectBrowserFlags import SourcesBrowserFlag, FormsBrowserFlag, \ |
32 ResourcesBrowserFlag, TranslationsBrowserFlag, InterfacesBrowserFlag, \ |
32 ResourcesBrowserFlag, TranslationsBrowserFlag, InterfacesBrowserFlag, \ |
33 OthersBrowserFlag, AllBrowsersFlag |
33 OthersBrowserFlag, AllBrowsersFlag |
34 |
34 |
35 class ProjectBrowser(E4TabWidget): |
35 class ProjectBrowser(E5TabWidget): |
36 """ |
36 """ |
37 Class implementing the project browser part of the eric5 UI. |
37 Class implementing the project browser part of the eric5 UI. |
38 |
38 |
39 It generates a widget with up to seven tabs. The individual tabs contain |
39 It generates a widget with up to seven tabs. The individual tabs contain |
40 the project sources browser, the project forms browser, |
40 the project sources browser, the project forms browser, |
53 @param embeddedBrowser flag indicating whether the file browser should |
53 @param embeddedBrowser flag indicating whether the file browser should |
54 be included. This flag is set to False by those layouts, that |
54 be included. This flag is set to False by those layouts, that |
55 have the file browser in a separate window or embedded |
55 have the file browser in a separate window or embedded |
56 in the debeug browser instead |
56 in the debeug browser instead |
57 """ |
57 """ |
58 E4TabWidget.__init__(self, parent) |
58 E5TabWidget.__init__(self, parent) |
59 self.project = project |
59 self.project = project |
60 |
60 |
61 self.setWindowIcon(UI.PixmapCache.getIcon("eric.png")) |
61 self.setWindowIcon(UI.PixmapCache.getIcon("eric.png")) |
62 |
62 |
63 self.vcsStatusIndicator = E4Led(self) |
63 self.vcsStatusIndicator = E5Led(self) |
64 self.setCornerWidget(self.vcsStatusIndicator, Qt.TopLeftCorner) |
64 self.setCornerWidget(self.vcsStatusIndicator, Qt.TopLeftCorner) |
65 self.vcsStatusColorNames = { |
65 self.vcsStatusColorNames = { |
66 "A" : "VcsAdded", |
66 "A" : "VcsAdded", |
67 "M" : "VcsModified", |
67 "M" : "VcsModified", |
68 "R" : "VcsReplaced", |
68 "R" : "VcsReplaced", |
231 """ |
231 """ |
232 Protected method handleing the show event. |
232 Protected method handleing the show event. |
233 |
233 |
234 @param evt show event to handle (QShowEvent) |
234 @param evt show event to handle (QShowEvent) |
235 """ |
235 """ |
236 E4TabWidget.showEvent(self, evt) |
236 E5TabWidget.showEvent(self, evt) |
237 if self.embeddedBrowser: |
237 if self.embeddedBrowser: |
238 self.fileBrowser.layoutDisplay() |
238 self.fileBrowser.layoutDisplay() |
239 |
239 |
240 def __currentChanged(self, index): |
240 def __currentChanged(self, index): |
241 """ |
241 """ |