eric7.TrayStarter.TrayStarter

Module implementing a starter for the system tray.

Global Attributes

None

Classes

TrayStarter Class implementing a starter for the system tray.

Functions

None


TrayStarter

Class implementing a starter for the system tray.

Derived from

QSystemTrayIcon

Class Attributes

None

Class Methods

None

Methods

TrayStarter Constructor
__about Private slot to handle the About dialog.
__activated Private slot to handle the activated signal.
__buildMenu Private method to build the tray starter menu.
__editDone Private slot to handle the finished signal of the menu editor dialog.
__editMenu Private slot to open a dialog to edit the variable part of the tray starter menu.
__getApplicationPath Private method to search for the given application and return its absolute path.
__getDefaultMenuItems Private method to build the default menu items.
__loadCustomMenuItems Private method to load an user defined menu structure.
__loadRecentFiles Private method to load the recently opened filenames.
__loadRecentMultiProjects Private method to load the recently opened multi project filenames.
__loadRecentProjects Private method to load the recently opened project filenames.
__openRecent Private method to open a project or file from the list of recently opened projects or files.
__populateMenu Private method to populate a given menu with items.
__restart Private slot to restart the tray starter.
__showContextMenu Private slot to show the context menu.
__showPreferences Private slot to set the preferences.
__showRecentFilesMenu Private method to set up the recent files menu.
__showRecentMultiProjectsMenu Private method to set up the recent multi projects menu.
__showRecentProjectsMenu Private method to set up the recent projects menu.
__showVersions Private slot to handle the Versions dialog.
__startProc Private method to start an eric application.
checkSystemTrayAvailable Public slot to check for the availability of a system tray and abort, if it is not available.
preferencesChanged Public slot to handle a change of preferences.

Static Methods

None

TrayStarter (Constructor)

TrayStarter(settingsDir, localeName)

Constructor

settingsDir (str)
directory to be used for the settings files
localeName (str)
name of the locale to be used for the translations

TrayStarter.__about

__about()

Private slot to handle the About dialog.

TrayStarter.__activated

__activated(reason)

Private slot to handle the activated signal.

reason (QSystemTrayIcon.ActivationReason)
reason code of the signal

TrayStarter.__buildMenu

__buildMenu()

Private method to build the tray starter menu.

TrayStarter.__editDone

__editDone()

Private slot to handle the finished signal of the menu editor dialog.

TrayStarter.__editMenu

__editMenu()

Private slot to open a dialog to edit the variable part of the tray starter menu.

TrayStarter.__getApplicationPath

__getApplicationPath(applName)

Private method to search for the given application and return its absolute path.

The search starts in the main eric7 directory and then searches in the 'Scripts' subdirectories of the user and global plugin area.

applName (str)
application to search for
Return:
absolute path to the application
Return Type:
str

TrayStarter.__getDefaultMenuItems

__getDefaultMenuItems()

Private method to build the default menu items.

Return:
list of default menu items
Return Type:
list[TrayStarterAction | TrayStarterSeparator | TrayStarterMenu]

TrayStarter.__loadCustomMenuItems

__loadCustomMenuItems()

Private method to load an user defined menu structure.

Return:
list of menu items to be included in the central menu part
Return Type:
list[TrayStarterAction | TrayStarterSeparator | TrayStarterMenu]

TrayStarter.__loadRecentFiles

__loadRecentFiles()

Private method to load the recently opened filenames.

TrayStarter.__loadRecentMultiProjects

__loadRecentMultiProjects()

Private method to load the recently opened multi project filenames.

TrayStarter.__loadRecentProjects

__loadRecentProjects()

Private method to load the recently opened project filenames.

TrayStarter.__openRecent

__openRecent(act)

Private method to open a project or file from the list of recently opened projects or files.

act (QAction)
reference to the action that triggered

TrayStarter.__populateMenu

__populateMenu(menu, items)

Private method to populate a given menu with items.

menu (QMenu)
reference to the menu to be populated
items (list[TrayStarterAction | TrayStarterSeparator | TrayStarterMenu])
list of menu items

TrayStarter.__restart

__restart()

Private slot to restart the tray starter.

TrayStarter.__showContextMenu

__showContextMenu()

Private slot to show the context menu.

TrayStarter.__showPreferences

__showPreferences()

Private slot to set the preferences.

TrayStarter.__showRecentFilesMenu

__showRecentFilesMenu()

Private method to set up the recent files menu.

TrayStarter.__showRecentMultiProjectsMenu

__showRecentMultiProjectsMenu()

Private method to set up the recent multi projects menu.

TrayStarter.__showRecentProjectsMenu

__showRecentProjectsMenu()

Private method to set up the recent projects menu.

TrayStarter.__showVersions

__showVersions()

Private slot to handle the Versions dialog.

TrayStarter.__startProc

__startProc(applName, *applArgs)

Private method to start an eric application.

applName (str)
name of the eric application script
*applArgs (list of str)
variable list of application arguments

TrayStarter.checkSystemTrayAvailable

checkSystemTrayAvailable()

Public slot to check for the availability of a system tray and abort, if it is not available.

TrayStarter.preferencesChanged

preferencesChanged()

Public slot to handle a change of preferences.

Up