KIO
kbookmarkmenu.cc
Go to the documentation of this file.
86 connect(m_parentMenu, SIGNAL(customContextMenuRequested(const QPoint &)), this, SLOT(slotCustomContextMenu(const QPoint &)));
133 connect(m_parentMenu, SIGNAL(customContextMenuRequested(const QPoint &)), this, SLOT(slotCustomContextMenu(const QPoint &)));
232 KBookmarkContextMenu::KBookmarkContextMenu(const KBookmark & bk, KBookmarkManager * manager, KBookmarkOwner *owner, QWidget * parent)
295 addAction(KIcon("tab-new"), i18n( "Open Folder in Tabs" ), this, SLOT( slotOpenFolderInTabs() ) );
410 //kDebug(7043) << "KBookmarkMenu::slotBookmarksChanged -> setting m_bDirty on " << groupAddress;
459 connect( paOpenFolderInTabs, SIGNAL( triggered( bool ) ), this, SLOT( slotOpenFolderInTabs() ) );
467 if( !m_pOwner || !m_pOwner->enableOption(KBookmarkOwner::ShowAddBookmark) || !m_pOwner->supportsTabs() || !KAuthorized::authorizeKAction("bookmarks") )
476 connect( d->bookmarksToFolder, SIGNAL( triggered( bool ) ), this, SLOT( slotAddBookmarksList() ) );
484 if( !m_pOwner || !m_pOwner->enableOption(KBookmarkOwner::ShowAddBookmark) || !KAuthorized::authorizeKAction("bookmarks") )
502 if( ( m_pOwner && !m_pOwner->enableOption(KBookmarkOwner::ShowEditBookmark) ) || !KAuthorized::authorizeKAction("bookmarks") )
505 KAction * m_paEditBookmarks = m_actionCollection->addAction(KStandardAction::EditBookmarks, "edit_bookmarks",
513 if( !m_pOwner || !m_pOwner->enableOption(KBookmarkOwner::ShowAddBookmark) || !KAuthorized::authorizeKAction("bookmarks"))
550 KBookmarkMenu *subMenu = new KBookmarkMenu( m_pManager, m_pOwner, actionMenu->menu(), bm.address() );
687 void KBookmarkMenuImporter::newBookmark( const QString & text, const QString & url, const QString & )
701 KImportedBookmarkMenu *subMenu = new KImportedBookmarkMenu( m_pManager, m_menu->owner(), actionMenu->menu());
757 KBookmarkActionMenu::KBookmarkActionMenu(const KBookmark &bm, const QString & text, QObject *parent)
QString i18n(const char *text)
KBookmarkAction(const KBookmark &bk, KBookmarkOwner *owner, QObject *parent)
Definition: kbookmarkmenu.cc:722
bool moveBookmark(const KBookmark &bookmark, const KBookmark &after)
Moves bookmark after after (which should be a child of ours).
Definition: kbookmark.cc:189
static KBookmarkImporterBase * factory(const QString &type)
Definition: kbookmarkimporter.cc:85
virtual void openBookmark(const KBookmark &bm, Qt::MouseButtons mb, Qt::KeyboardModifiers km)=0
Called if a bookmark is selected.
KBookmark previous(const KBookmark ¤t) const
Return the prevous sibling of a child bookmark of this group.
Definition: kbookmark.cc:118
KBookmarkActionInterface(const KBookmark &bk)
Definition: kbookmarkmenu.cc:214
KBookmarkGroup createNewFolder(const QString &name, KBookmark parent=KBookmark())
A dialog to create a new folder.
Definition: kbookmarkdialog.cc:151
virtual QAction * actionForBookmark(const KBookmark &bm)
Definition: kbookmarkmenu.cc:543
void setKeyboardShortcutsEnabled(bool enable)
virtual ~KBookmarkContextMenu()
Definition: kbookmarkmenu.cc:258
void deleteBookmark(const KBookmark &bk)
Delete a bookmark - it has to be one of our children ! Don't forget to use KBookmarkManager::self()->...
Definition: kbookmark.cc:237
KBookmarkMenu(KBookmarkManager *mgr, KBookmarkOwner *owner, KMenu *parentMenu, KActionCollection *collec)
Fills a bookmark menu (one instance of KBookmarkMenu is created for the toplevel menu, but also one per submenu).
Definition: kbookmarkmenu.cc:65
void ensureUpToDate()
Call ensureUpToDate() if you need KBookmarkMenu to adjust to its final size before it is executed...
Definition: kbookmarkmenu.cc:145
KBookmarkActionMenu(const KBookmark &bm, QObject *parent)
Definition: kbookmarkmenu.cc:749
virtual bool enableOption(BookmarkOption option) const
Returns true if action should be shown in the menu The default is to show both a add and editBookmark...
Definition: kbookmarkmanager.cc:703
void slotBookmarksChanged(const QString &)
Definition: kbookmarkmenu.cc:405
KBookmarkGroup toGroup() const
Convert this to a group - do this only if isGroup() returns true.
Definition: kbookmark.cc:465
QAction * addAction(const QString &name, QAction *action)
void slotEditBookmarksAtAddress(const QString &address)
Definition: kbookmarkmanager.cc:627
This class implements the reading/writing of bookmarks in XML.
Definition: kbookmarkmanager.h:65
virtual QString currentTitle() const
This function is called whenever the user wants to add the current page to the bookmarks list...
Definition: kbookmarkmanager.h:396
static QDebug kDebug(bool cond, int area=KDE_DEFAULT_DEBUG_AREA)
Definition: kbookmark.h:34
KGuiItem del()
void newFolder(const QString &text, bool, const QString &)
Definition: kbookmarkmenu.cc:695
QString text() const
Text shown for the bookmark If bigger than 40, the text is shortened by replacing middle characters w...
Definition: kbookmark.cc:306
KBookmark addBookmark(const QString &title, const KUrl &url, KBookmark parent=KBookmark())
shows a add Bookmark dialog Note: That this updates the bookmark and calls KBookmarkManager::emitChan...
Definition: kbookmarkdialog.cc:63
KMenu * parentMenu() const
The menu in which we insert our actions Supplied in the constructor.
Definition: kbookmarkmenu.cc:205
void slotSelected(Qt::MouseButtons mb, Qt::KeyboardModifiers km)
Definition: kbookmarkmenu.cc:741
KBookmark addBookmark(const KBookmark &bm)
Create a new bookmark, as the last child of this group Don't forget to use KBookmarkManager::self()->...
Definition: kbookmark.cc:212
void setFilename(const QString &filename)
Definition: kbookmarkimporter.h:41
void newBookmark(const QString &text, const QString &url, const QString &)
Definition: kbookmarkmenu.cc:687
KBookmark editBookmark(const KBookmark &bm)
shows a propeties dialog Note: That this updates the bookmark and calls KBookmarkManager::emitChanged...
Definition: kbookmarkdialog.cc:36
bool isGroup() const
Whether the bookmark is a group or a normal bookmark.
Definition: kbookmark.cc:283
void slotOpenFolderInTabs()
Definition: kbookmarkmenu.cc:381
QString csqueeze(const QString &str, int maxlen=40)
The KBookmarkMenu and KBookmarkBar classes gives the user the ability to either edit bookmarks or add...
Definition: kbookmarkmanager.h:382
Definition: kbookmarkmenu.h:255
virtual KBookmarkDialog * bookmarkDialog(KBookmarkManager *mgr, QWidget *parent)
Definition: kbookmarkmanager.cc:712
virtual ~KBookmarkActionInterface()
Definition: kbookmarkmenu.cc:218
KMenu * menu()
virtual void openFolderinTabs(const KBookmarkGroup &bm)
Called if the user wants to open every bookmark in this folder in a new tab.
Definition: kbookmarkmanager.cc:717
void connectToImporter(const QObject &importer)
Definition: kbookmarkmenu.cc:677
void populateMimeData(QMimeData *mimeData) const
Adds this bookmark into the given QMimeData.
Definition: kbookmark.cc:659
KImportedBookmarkMenu(KBookmarkManager *mgr, KBookmarkOwner *owner, KMenu *parentMenu, const QString &type, const QString &location)
Definition: kbookmarkmenu.cc:628
Definition: kbookmarkmenu.h:188
KBookmarkGroup addBookmarks(const QList< QPair< QString, QString > > &list, const QString &name=QString(), KBookmarkGroup parent=KBookmarkGroup())
Creates a folder from a list of bookmarks Note: That this updates the bookmark and calls KBookmarkMan...
Definition: kbookmarkdialog.cc:92
KAction * replace(const QObject *recvr, const char *slot, QObject *parent)
KBookmark findByAddress(const QString &address)
Definition: kbookmarkmanager.cc:515
void triggered(Qt::MouseButtons buttons, Qt::KeyboardModifiers modifiers)
void emitChanged()
Saves the bookmark file and notifies everyone.
Definition: kbookmarkmanager.cc:545
virtual QList< QPair< QString, QString > > currentBookmarkList() const
Returns a list of title, URL pairs of the open tabs.
Definition: kbookmarkmanager.h:420
~KImportedBookmarkMenu()
Definition: kbookmarkmenu.cc:643
virtual KMenu * contextMenu(QAction *action)
Definition: kbookmarkmenu.cc:172
void openBookmarks(const QString &location, const QString &type)
Definition: kbookmarkmenu.cc:663
void setHelpText(const QString &text)
A class connected to KNSBookmarkImporter, to fill KActionMenus.
Definition: kbookmarkmenu_p.h:97
virtual bool supportsTabs() const
This function returns whether the owner supports tabs.
Definition: kbookmarkmanager.h:414
static KBookmark standaloneBookmark(const QString &text, const KUrl &url, const QString &icon=QString())
Creates a stand alone bookmark.
Definition: kbookmark.cc:501
A class for importing NS bookmarks KEditBookmarks uses it to insert bookmarks into its DOM tree...
Definition: kbookmarkimporter.h:34
Definition: kbookmarkmenu_p.h:51
KBookmarkContextMenu(const KBookmark &bm, KBookmarkManager *manager, KBookmarkOwner *owner, QWidget *parent=0)
Definition: kbookmarkmenu.cc:232
virtual void parse()=0
virtual QString currentUrl() const
This function is called whenever the user wants to add the current page to the bookmarks list...
Definition: kbookmarkmanager.h:407
KActionCollection * m_actionCollection
Definition: kbookmarkmenu.h:164
KBookmark next(const KBookmark ¤t) const
Return the next sibling of a child bookmark of this group.
Definition: kbookmark.cc:123
const KShortcut & end()
Definition: kbookmarkmenu.h:225
Definition: kbookmarkmenu_p.h:119
static int warningContinueCancel(QWidget *parent, const QString &text, const QString &caption=QString(), const KGuiItem &buttonContinue=KStandardGuiItem::cont(), const KGuiItem &buttonCancel=KStandardGuiItem::cancel(), const QString &dontAskAgainName=QString(), Options options=Notify)
This class provides a Dialog for editing properties, adding Bookmarks and creating new folders...
Definition: kbookmarkdialog.h:44
bool authorizeKAction(const QString &action)
virtual ~KBookmarkActionMenu()
Definition: kbookmarkmenu.cc:763
Definition: kbookmarkmenu.h:240
QStack< KImportedBookmarkMenu * > mstack
Definition: kbookmarkmenu_p.h:114
static void error(QWidget *parent, const QString &text, const QString &caption=QString(), Options options=Notify)
QString address() const
Return the "address" of this bookmark in the whole tree.
Definition: kbookmark.cc:471
This file is part of the KDE documentation.
Documentation copyright © 1996-2014 The KDE developers.
Generated on Tue Oct 14 2014 22:50:02 by doxygen 1.8.7 written by Dimitri van Heesch, © 1997-2006
Documentation copyright © 1996-2014 The KDE developers.
Generated on Tue Oct 14 2014 22:50:02 by doxygen 1.8.7 written by Dimitri van Heesch, © 1997-2006
KDE's Doxygen guidelines are available online.