• Skip to content
  • Skip to link menu
KDE API Reference
  • KDE API Reference
  • kde-baseapps API Reference
  • KDE Home
  • Contact Us
 

libkonq

  • sources
  • kde-4.14
  • kde-baseapps
  • lib
  • konq
konq_menuactions.cpp
Go to the documentation of this file.
1 /* This file is part of the KDE project
2  Copyright (C) 1998-2009 David Faure <faure@kde.org>
3 
4  This library is free software; you can redistribute it and/or modify
5  it under the terms of the GNU Library General Public License as published
6  by the Free Software Foundation; either version 2 of the License or
7  ( at your option ) version 3 or, at the discretion of KDE e.V.
8  ( which shall act as a proxy as in section 14 of the GPLv3 ), any later version.
9 
10  This library is distributed in the hope that it will be useful,
11  but WITHOUT ANY WARRANTY; without even the implied warranty of
12  MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
13  Library General Public License for more details.
14 
15  You should have received a copy of the GNU Library General Public License
16  along with this library; see the file COPYING.LIB. If not, write to
17  the Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor,
18  Boston, MA 02110-1301, USA.
19 */
20 
21 #include "konq_menuactions.h"
22 #include <kfileitemlistproperties.h>
23 #include <kfileitemactions.h>
24 #include "konq_popupmenuinformation.h"
25 
26 KonqMenuActions::KonqMenuActions()
27  : d(new KFileItemActions)
28 {
29 }
30 
31 
32 KonqMenuActions::~KonqMenuActions()
33 {
34  delete d;
35 }
36 
37 void KonqMenuActions::setPopupMenuInfo(const KonqPopupMenuInformation& info)
38 {
39  d->setItemListProperties(info.itemListProperties());
40 }
41 
42 void KonqMenuActions::setItemListProperties(const KFileItemListProperties& itemListProperties)
43 {
44  d->setItemListProperties(itemListProperties);
45 }
46 
47 int KonqMenuActions::addActionsTo(QMenu* mainMenu)
48 {
49  return d->addServiceActionsTo(mainMenu);
50 }
51 
52 void KonqMenuActions::addOpenWithActionsTo(QMenu* topMenu, const QString& traderConstraint)
53 {
54  d->addOpenWithActionsTo(topMenu, traderConstraint);
55 }
56 
57 KAction* KonqMenuActions::preferredOpenWithAction(const QString& traderConstraint)
58 {
59  return d->preferredOpenWithAction(traderConstraint);
60 }
61 
62 void KonqMenuActions::setParentWidget(QWidget* widget)
63 {
64  d->setParentWidget(widget);
65 }
QWidget
konq_popupmenuinformation.h
KonqPopupMenuInformation::itemListProperties
KFileItemListProperties itemListProperties() const
Returns the list of items and their properties.
Definition: konq_popupmenuinformation.cpp:105
KonqMenuActions::addOpenWithActionsTo
void addOpenWithActionsTo(QMenu *menu, const QString &traderConstraint)
Generate the "Open With " actions, and adds them to the menu.
Definition: konq_menuactions.cpp:52
KonqMenuActions::setParentWidget
void setParentWidget(QWidget *widget)
Set the parent widget for any dialogs being shown.
Definition: konq_menuactions.cpp:62
konq_menuactions.h
KonqMenuActions::preferredOpenWithAction
KAction * preferredOpenWithAction(const QString &traderConstraint)
Returns an action for the preferred app only.
Definition: konq_menuactions.cpp:57
QString
KonqMenuActions::addActionsTo
int addActionsTo(QMenu *menu)
Generate the user-defined actions and submenus, and adds them to the menu.
Definition: konq_menuactions.cpp:47
QMenu
KonqMenuActions::~KonqMenuActions
~KonqMenuActions()
Destructor.
Definition: konq_menuactions.cpp:32
KonqMenuActions::setPopupMenuInfo
KDE_DEPRECATED void setPopupMenuInfo(const KonqPopupMenuInformation &info)
Sets all the data for the next instance of the popupmenu.
Definition: konq_menuactions.cpp:37
KonqMenuActions::setItemListProperties
void setItemListProperties(const KFileItemListProperties &itemList)
Sets all the data for the next instance of the popupmenu.
Definition: konq_menuactions.cpp:42
KonqMenuActions::KonqMenuActions
KonqMenuActions()
Creates a KonqMenuActions instance.
Definition: konq_menuactions.cpp:26
KonqPopupMenuInformation
Holds the information about the items shown by KonqPopupMenu.
Definition: konq_popupmenuinformation.h:43
This file is part of the KDE documentation.
Documentation copyright © 1996-2020 The KDE developers.
Generated on Mon Jun 22 2020 13:07:48 by doxygen 1.8.7 written by Dimitri van Heesch, © 1997-2006

KDE's Doxygen guidelines are available online.

libkonq

Skip menu "libkonq"
  • Main Page
  • Namespace List
  • Alphabetical List
  • Class List
  • Class Hierarchy
  • Class Members
  • File List
  • File Members
  • Related Pages

kde-baseapps API Reference

Skip menu "kde-baseapps API Reference"
  • Libraries
  •   libkonq

Search



Report problems with this website to our bug tracking system.
Contact the specific authors with questions and comments about the page contents.

KDE® and the K Desktop Environment® logo are registered trademarks of KDE e.V. | Legal