22 #include <kapplication.h>
25 #include <kstandarddirs.h>
29 #include "knewstuff.h"
33 KAction* KNS::standardAction(
const TQString& what,
34 const TQObject *recvr,
35 const char *slot, KActionCollection* parent,
38 return new KAction(i18n(
"Download New %1").arg(what),
"knewstuff",
39 0, recvr, slot, parent, name);
44 mEngine =
new Engine(
this, type, parentWidget );
49 mEngine =
new Engine(
this, type, providerList, parentWidget );
54 return mEngine->type();
59 return mEngine->parentWidget();
62 KNewStuff::~KNewStuff()
74 return KGlobal::dirs()->saveLocation(
"tmp" ) +
75 KApplication::randomString( 10 );
85 mEngine->upload(fileName, previewName);
KNewStuff(const TQString &type, TQWidget *parentWidget=0)
Constructor.
KNewStuff data entry container.
void download()
Start download process.
TQString type() const
Return type of data.
virtual TQString downloadDestination(KNS::Entry *entry)
Return a filename which should be used as destination for downloading the specified new stuff entry...
TQWidget * parentWidget() const
Return parent widget.
Handles security releated issues, like signing, verifying.
Central class combining all possible KNewStuff operations.
void upload()
Start upload process.