KonqPopupMenu Class Reference

#include <konq_popupmenu.h>

Inheritance diagram for KonqPopupMenu:
KonqXMLGUIClient

List of all members.

Classes

class  KonqPopupMenuPrivate
class  ProtocolInfo

Public Types

enum  { NoFlags = 0, ShowProperties = 1, IsLink = 2, ShowNewWindow = 4 }
typedef uint KonqPopupFlags

Public Slots

void slotPopupNewDir ()
void slotPopupNewView ()
void slotPopupEmptyTrashBin ()
void slotPopupRestoreTrashedItems ()
void slotPopupOpenWith ()
void slotPopupAddToBookmark ()
void slotRunService ()
void slotPopupMimeType ()
void slotPopupProperties ()
void slotOpenShareFileDialog ()

Public Member Functions

 KonqPopupMenu (KBookmarkManager *manager, const KFileItemList &items, KURL viewURL, KActionCollection &actions, KNewMenu *newMenu, bool showPropertiesAndFileType=true) KDE_DEPRECATED
 KonqPopupMenu (KBookmarkManager *manager, const KFileItemList &items, KURL viewURL, KActionCollection &actions, KNewMenu *newMenu, TQWidget *parentWidget, bool showPropertiesAndFileType=true) KDE_DEPRECATED
 KonqPopupMenu (KBookmarkManager *manager, const KFileItemList &items, const KURL &viewURL, KActionCollection &actions, KNewMenu *newMenu, TQWidget *parentWidget, KonqPopupFlags kpf, KParts::BrowserExtension::PopupFlags f)
 ~KonqPopupMenu ()
void setURLTitle (const TQString &urlTitle)
virtual KAction * action (const TQDomElement &element) const
virtual KActionCollection * actionCollection () const
TQString mimeType () const
KURL url () const
KFileItemList fileItemList () const
KURL::List popupURLList () const
ProtocolInfo protocolInfo () const

Protected Attributes

KActionCollection & m_actions
KActionCollection m_ownActions

Detailed Description

This class implements the popup menu for URLs in konqueror and kdesktop It's usage is very simple : on right click, create the KonqPopupMenu instance with the correct arguments, then exec() to make it appear, then destroy it.


Member Typedef Documentation

Flags set by the calling application (konqueror/kdesktop), unlike KParts::BrowserExtension::PopupFlags, which are set by the calling part


Member Enumeration Documentation

anonymous enum
Enumerator:
ShowProperties 

whether to show the "Properties" menu item

IsLink 

HTML link. If set, we won't have cut/copy/paste, and we'll say "bookmark this link".


Constructor & Destructor Documentation

KonqPopupMenu::KonqPopupMenu ( KBookmarkManager *  manager,
const KFileItemList &  items,
KURL  viewURL,
KActionCollection &  actions,
KNewMenu newMenu,
bool  showPropertiesAndFileType = true 
)
Deprecated:
lacks parentWidget pointer, and uses bool instead of KonqPopupFlags enum, might do strange things with the 'new window' action.
KonqPopupMenu::KonqPopupMenu ( KBookmarkManager *  manager,
const KFileItemList &  items,
KURL  viewURL,
KActionCollection &  actions,
KNewMenu newMenu,
TQWidget parentWidget,
bool  showPropertiesAndFileType = true 
)
Deprecated:
uses bool instead of KonqPopupFlags enum, might do strange things with the 'new window' action.
KonqPopupMenu::KonqPopupMenu ( KBookmarkManager *  manager,
const KFileItemList &  items,
const KURL &  viewURL,
KActionCollection &  actions,
KNewMenu newMenu,
TQWidget parentWidget,
KonqPopupFlags  kpf,
KParts::BrowserExtension::PopupFlags  f 
)

Constructor

Parameters:
manager the bookmark manager for this bookmark
items the list of file items the popupmenu should be shown for
viewURL the URL shown in the view, to test for RMB click on view background
actions list of actions the caller wants to see in the menu
newMenu "New" menu, shared with the File menu, in konqueror
parentWidget the widget we're showing this popup for. Helps destroying the popup if the widget is destroyed before the popup.
kpf flags from the KonqPopupFlags enum, set by the calling application
f flags from the BrowserExtension enum, set by the calling part

The actions to pass in include : showmenubar, back, forward, up, cut, copy, paste, pasteto, trash, rename, del The others items are automatically inserted.

Since:
3.2
Todo:
that list is probably not be up-to-date
KonqPopupMenu::~KonqPopupMenu (  ) 

Don't forget to destroy the object


Member Function Documentation

KAction * KonqPopupMenu::action ( const TQDomElement &  element  )  const [virtual]

Reimplemented for internal purpose

void KonqPopupMenu::setURLTitle ( const TQString &  urlTitle  ) 

Set the title of the URL, when the popupmenu is opened for a single URL. This is used if the user chooses to add a bookmark for this URL.


The documentation for this class was generated from the following files:

Generated on Sat Oct 2 23:00:09 2010 by  doxygen 1.6.1