# eric7.WebBrowser.Bookmarks.BookmarksToolBar

Module implementing a tool bar showing bookmarks.

### Global Attributes

None

### Classes

BookmarksToolBar | Class implementing a tool bar showing bookmarks.

### Functions

None

## BookmarksToolBar

Class implementing a tool bar showing bookmarks.

### Signals

newTab(QUrl, str)
  emitted to open a URL in a new tab
newWindow(QUrl, str)
  emitted to open a URL in a new window
openUrl(QUrl, str)
  emitted to open a URL in the current tab

### Derived from

EricModelToolBar

### Class Attributes

None

### Class Methods

None

### Methods

BookmarksToolBar | Constructor
__bookmarkActivated | Private slot handling the activation of a bookmark.
__contextMenuRequested | Private slot to handle the context menu request.
__edit | Private slot to edit a bookmarks properties.
__newBookmark | Private slot to add a new bookmark.
__newFolder | Private slot to add a new bookmarks folder.
__openBookmark | Private slot to open a bookmark in the current browser tab.
__openBookmarkInNewTab | Private slot to open a bookmark in a new browser tab.
__openBookmarkInNewWindow | Private slot to open a bookmark in a new window.
__openBookmarkInPrivateWindow | Private slot to open a bookmark in a new private window.
__rebuild | Private slot to rebuild the toolbar.
__removeBookmark | Private slot to remove a bookmark.
__updateVisitCount | Private method to update the visit count of a bookmark.
_createMenu | Protected method to create the menu for a tool bar action.

### Static Methods

None

#### BookmarksToolBar (Constructor)

BookmarksToolBar(mainWindow, model, parent=None)

Constructor

mainWindow (WebBrowserWindow)
  reference to the main window
model (BookmarksModel)
  reference to the bookmarks model
parent (QWidget)
  reference to the parent widget

#### BookmarksToolBar.__bookmarkActivated

__bookmarkActivated(idx)

Private slot handling the activation of a bookmark.

idx (QModelIndex)
  index of the activated bookmark

#### BookmarksToolBar.__contextMenuRequested

__contextMenuRequested(pos)

Private slot to handle the context menu request.

pos (QPoint)
  position the context menu shall be shown

#### BookmarksToolBar.__edit

__edit(act)

Private slot to edit a bookmarks properties.

act (QAction)
  reference to the triggering action

#### BookmarksToolBar.__newBookmark

__newBookmark()

Private slot to add a new bookmark.

#### BookmarksToolBar.__newFolder

__newFolder()

Private slot to add a new bookmarks folder.

#### BookmarksToolBar.__openBookmark

__openBookmark(act)

Private slot to open a bookmark in the current browser tab.

act (QAction)
  reference to the triggering action

#### BookmarksToolBar.__openBookmarkInNewTab

__openBookmarkInNewTab(act)

Private slot to open a bookmark in a new browser tab.

act (QAction)
  reference to the triggering action

#### BookmarksToolBar.__openBookmarkInNewWindow

__openBookmarkInNewWindow(act)

Private slot to open a bookmark in a new window.

act (QAction)
  reference to the triggering action

#### BookmarksToolBar.__openBookmarkInPrivateWindow

__openBookmarkInPrivateWindow(act)

Private slot to open a bookmark in a new private window.

act (QAction)
  reference to the triggering action

#### BookmarksToolBar.__rebuild

__rebuild()

Private slot to rebuild the toolbar.

#### BookmarksToolBar.__removeBookmark

__removeBookmark(act)

Private slot to remove a bookmark.

act (QAction)
  reference to the triggering action

#### BookmarksToolBar.__updateVisitCount

__updateVisitCount(idx)

Private method to update the visit count of a bookmark.

idx (QModelIndex)
  index of the bookmark item

#### BookmarksToolBar._createMenu

_createMenu()

Protected method to create the menu for a tool bar action.

Return:
  menu for a tool bar action

Return Type:
  EricModelMenu

Up