• Skip to content
  • Skip to link menu
KDE API Reference
  • KDE API Reference
  • kdelibs API Reference
  • KDE Home
  • Contact Us
 

KNewStuff

  • sources
  • kde-4.12
  • kdelibs
  • knewstuff
  • knewstuff3
knewstuff3/uploaddialog.h
Go to the documentation of this file.
1 /*
2  knewstuff3/ui/uploaddialog.h.
3  Copyright (c) 2002 Cornelius Schumacher <schumacher@kde.org>
4  Copyright (C) 2007 Josef Spillner <spillner@kde.org>
5  Copyright (C) 2009 Jeremy Whiting <jpwhiting@kde.org>
6  Copyright (C) 2009-2010 Frederik Gladhorn <gladhorn@kde.org>
7 
8  This library is free software; you can redistribute it and/or
9  modify it under the terms of the GNU Lesser General Public
10  License as published by the Free Software Foundation; either
11  version 2.1 of the License, or (at your option) any later version.
12 
13  This library is distributed in the hope that it will be useful,
14  but WITHOUT ANY WARRANTY; without even the implied warranty of
15  MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
16  Lesser General Public License for more details.
17 
18  You should have received a copy of the GNU Lesser General Public
19  License along with this library. If not, see <http://www.gnu.org/licenses/>.
20 */
21 #ifndef KNEWSTUFF3_UI_UPLOADDIALOG_H
22 #define KNEWSTUFF3_UI_UPLOADDIALOG_H
23 
24 #include <kdialog.h>
25 #include <kurl.h>
26 
27 #include <knewstuff3/knewstuff_export.h>
28 
29 namespace Attica {
30  class BaseJob;
31  class Provider;
32 }
33 
34 // KDE5: this class should inherit from the wizard class - KAssistantDialog
35 
36 namespace KNS3
37 {
48 class KNEWSTUFF_EXPORT UploadDialog : public KDialog
49 {
50  Q_OBJECT
51 public:
57  explicit UploadDialog(QWidget *parent = 0);
58 
64  explicit UploadDialog(const QString& configFile, QWidget *parent = 0);
65 
69  ~UploadDialog();
70 
77  void setUploadFile(const KUrl& payloadFile);
78 
86  void setUploadName(const QString& name);
87 
93  void setVersion(const QString& version);
94 
100  void setDescription(const QString& description);
101 
107  void setChangelog(const QString& changelog);
108 
109  /* *
110  Set the suggested license displayed in the upload dialog.
111  The user can still change this.
112  @param version version
113  */
114  // enum License {}; // see fd.o api spec
115  // void setLicense(License license);
116 
124  void setPreviewImageFile(uint number, const KUrl& file);
125 
131  void setPriceEnabled(bool enabled);
132 
138  void setPrice(double price);
139 
145  void setPriceReason(const QString& reason);
146 
154  void selectCategory(const QString& category);
155 
156 public Q_SLOTS:
157  virtual void accept();
158 
159 private:
160  bool init(const QString &configfile);
161 
162  class Private;
163  Private *const d;
164 
165  Q_PRIVATE_SLOT( d, void _k_nextPage() )
166  Q_PRIVATE_SLOT( d, void _k_backPage() )
167  Q_PRIVATE_SLOT( d, void _k_updatePage() )
168 
169  Q_PRIVATE_SLOT( d, void _k_providerChanged(QString) )
170  Q_PRIVATE_SLOT( d, void _k_checkCredentialsFinished(bool) )
171  Q_PRIVATE_SLOT( d, void _k_contentByCurrentUserLoaded(Attica::Content::List) )
172  Q_PRIVATE_SLOT( d, void _k_providersLoaded(QStringList) )
173  Q_PRIVATE_SLOT( d, void _k_categoriesLoaded(Attica::Category::List) )
174  Q_PRIVATE_SLOT( d, void _k_licensesLoaded(Attica::License::List) )
175  Q_PRIVATE_SLOT( d, void _k_currencyLoaded(QString) )
176  Q_PRIVATE_SLOT( d, void _k_previewLoaded(int, QImage) )
177 
178  Q_PRIVATE_SLOT( d, void _k_changePreview1() )
179  Q_PRIVATE_SLOT( d, void _k_changePreview2() )
180  Q_PRIVATE_SLOT( d, void _k_changePreview3() )
181  Q_PRIVATE_SLOT( d, void _k_priceToggled(bool) )
182  Q_PRIVATE_SLOT( d, void _k_updateContentsToggled(bool update) )
183 
184  Q_PRIVATE_SLOT( d, void _k_startUpload() )
185  Q_PRIVATE_SLOT( d, void _k_contentAdded(Attica::BaseJob*) )
186  Q_PRIVATE_SLOT( d, void _k_fileUploadFinished(Attica::BaseJob*) )
187  Q_PRIVATE_SLOT( d, void _k_preview1UploadFinished(Attica::BaseJob*) )
188  Q_PRIVATE_SLOT( d, void _k_preview2UploadFinished(Attica::BaseJob*) )
189  Q_PRIVATE_SLOT( d, void _k_preview3UploadFinished(Attica::BaseJob*) )
190 
191  Q_PRIVATE_SLOT( d, void _k_updatedContentFetched(Attica::Content) )
192  Q_PRIVATE_SLOT( d, void _k_detailsLinkLoaded(QUrl) )
193 
194  Q_PRIVATE_SLOT( d, void _k_openRegisterAccountWebpage(QString) )
195 
196  Q_DISABLE_COPY( UploadDialog )
197 };
198 
199 }
200 
201 #endif
kdialog.h
KNS3::UploadDialog::Private
Definition: uploaddialog_p.h:40
kurl.h
QWidget
name
const char * name(StandardAction id)
KNS3::UploadDialog
KNewStuff file upload dialog.
Definition: knewstuff3/uploaddialog.h:48
KDialog
QUrl
QString
KUrl
QStringList
knewstuff_export.h
version
unsigned int version()
number
QString number(KIO::filesize_t size)
This file is part of the KDE documentation.
Documentation copyright © 1996-2014 The KDE developers.
Generated on Tue Oct 14 2014 22:50:49 by doxygen 1.8.7 written by Dimitri van Heesch, © 1997-2006

KDE's Doxygen guidelines are available online.

KNewStuff

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

kdelibs API Reference

Skip menu "kdelibs API Reference"
  • DNSSD
  • Interfaces
  •   KHexEdit
  •   KMediaPlayer
  •   KSpeech
  •   KTextEditor
  • kconf_update
  • KDE3Support
  •   KUnitTest
  • KDECore
  • KDED
  • KDEsu
  • KDEUI
  • KDEWebKit
  • KDocTools
  • KFile
  • KHTML
  • KImgIO
  • KInit
  • kio
  • KIOSlave
  • KJS
  •   KJS-API
  • kjsembed
  •   WTF
  • KNewStuff
  • KParts
  • KPty
  • Kross
  • KUnitConversion
  • KUtils
  • Nepomuk
  • Nepomuk-Core
  • Nepomuk
  • Plasma
  • Solid
  • Sonnet
  • ThreadWeaver

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