# eric7.Plugins.VcsPlugins.vcsMercurial.ShelveExtension.ProjectBrowserHelper

Module implementing the shelve extension project browser helper.

### Global Attributes

None

### Classes

ShelveProjectBrowserHelper | Class implementing the shelve extension project browser helper.

### Functions

None

## ShelveProjectBrowserHelper

Class implementing the shelve extension project browser helper.

### Derived from

HgExtensionProjectBrowserHelper

### Class Attributes

None

### Class Methods

None

### Methods

ShelveProjectBrowserHelper | Constructor
__hgShelve | Private slot used to shelve all current changes.
__reopenProject | Private method to reopen the project if needed and wanted.
initMenus | Public method to generate the extension menus.
menuTitle | Public method to get the menu title.
showExtensionMenu | Public method to prepare the extension menu for display.

### Static Methods

None

#### ShelveProjectBrowserHelper (Constructor)

ShelveProjectBrowserHelper(vcsObject, browserObject, projectObject)

Constructor

vcsObject (Hg)
  reference to the vcs object
browserObject (ProjectBaseBrowser)
  reference to the project browser object
projectObject (Project)
  reference to the project object

#### ShelveProjectBrowserHelper.__hgShelve

__hgShelve()

Private slot used to shelve all current changes.

#### ShelveProjectBrowserHelper.__reopenProject

__reopenProject(shouldReopen, title)

Private method to reopen the project if needed and wanted.

shouldReopen (bool)
  flag indicating that the project should be reopened
title (str)
  title of the message box

#### ShelveProjectBrowserHelper.initMenus

initMenus()

Public method to generate the extension menus.

Return:
  dictionary of populated menu. The dict must have the keys 'mainMenu', 'multiMenu', 'backMenu', 'dirMenu' and 'dirMultiMenu'.

Return Type:
  dict of QMenu

#### ShelveProjectBrowserHelper.menuTitle

menuTitle()

Public method to get the menu title.

Return:
  title of the menu

Return Type:
  str

#### ShelveProjectBrowserHelper.showExtensionMenu

showExtensionMenu(key, controlled)

Public method to prepare the extension menu for display.

key (str)
  menu key (one of 'mainMenu', 'multiMenu', 'backMenu', 'dirMenu' or 'dirMultiMenu')
controlled (bool)
  flag indicating to prepare the menu for a version controlled entry or a non-version controlled entry

Up