Eneboo - Documentación para desarrolladores
|
00001 /*************************************************************************** 00002 AQSUriDrag_p.h 00003 ------------------- 00004 begin : 22/02/2011 00005 copyright : (C) 2003-2011 by InfoSiAL S.L. 00006 email : mail@infosial.com 00007 ***************************************************************************/ 00008 /*************************************************************************** 00009 * This program is free software; you can redistribute it and/or modify * 00010 * it under the terms of the GNU General Public License as published by * 00011 * the Free Software Foundation; version 2 of the License. * 00012 ***************************************************************************/ 00013 /*************************************************************************** 00014 Este programa es software libre. Puede redistribuirlo y/o modificarlo 00015 bajo los términos de la Licencia Pública General de GNU en su 00016 versión 2, publicada por la Free Software Foundation. 00017 ***************************************************************************/ 00018 00019 #ifndef AQSURIDRAG_P_H_ 00020 #define AQSURIDRAG_P_H_ 00021 00022 #include "AQSStoredDrag_p.h" 00023 00024 class AQSUriDrag : public AQSStoredDrag 00025 { 00026 Q_OBJECT 00027 00028 AQ_DECLARE_AQS_OBJECT(UriDrag, StoredDrag); 00029 00030 //@AQ_BEGIN_DEF_PUB_SLOTS@ 00031 public slots: 00032 void setFileNames(const QStringList &); 00033 void setUnicodeUris(const QStringList &); 00034 QString uriToLocalFile(const char *); 00035 QCString localFileToUri(const QString &); 00036 QString uriToUnicodeUri(const char *); 00037 QCString unicodeUriToUri(const QString &); 00038 bool canDecode(const QMimeSource *); 00039 00040 protected: 00041 static void *construct(const QSArgumentList &args) { 00042 QMap<int, QStringList> candidates; 00043 candidates[0].append(QString::null); 00044 candidates[1].append(QString::fromLatin1("QWidget*")); 00045 candidates[2].append(QString::fromLatin1("QWidget*,QString")); 00046 QString sgt(castArgsSignature(args, candidates)); 00047 if (sgt.isEmpty()) 00048 return new QUriDrag; 00049 if (sgt == QString::fromLatin1("QWidget*")) 00050 return new QUriDrag(argValue<QWidget *>(args[0])); 00051 if (sgt == QString::fromLatin1("QWidget*,QString")) 00052 return new QUriDrag(argValue<QWidget *>(args[0]), 00053 *(argValue<QString *>(args[1]))); 00054 return 0; 00055 } 00056 00057 public: 00058 static QMap<int, QStringList> candidateConstructors() { 00059 QMap<int, QStringList> candidates; 00060 candidates[0].append(QString::null); 00061 candidates[1].append(QString::fromLatin1("QWidget*")); 00062 candidates[2].append(QString::fromLatin1("QWidget*,QString")); 00063 return candidates; 00064 } 00065 //@AQ_END_DEF_PUB_SLOTS@ 00066 }; 00067 00068 //@AQ_BEGIN_IMP_PUB_SLOTS@ 00069 inline void AQSUriDrag::setFileNames(const QStringList &arg0) 00070 { 00071 AQ_CALL_VOID(setFileNames(arg0)); 00072 } 00073 inline void AQSUriDrag::setUnicodeUris(const QStringList &arg0) 00074 { 00075 AQ_CALL_VOID(setUnicodeUris(arg0)); 00076 } 00077 inline QString AQSUriDrag::uriToLocalFile(const char *arg0) 00078 { 00079 AQ_CALL_RET_V(uriToLocalFile(arg0), QString); 00080 } 00081 inline QCString AQSUriDrag::localFileToUri(const QString &arg0) 00082 { 00083 AQ_CALL_RET_V(localFileToUri(arg0), QCString); 00084 } 00085 inline QString AQSUriDrag::uriToUnicodeUri(const char *arg0) 00086 { 00087 AQ_CALL_RET_V(uriToUnicodeUri(arg0), QString); 00088 } 00089 inline QCString AQSUriDrag::unicodeUriToUri(const QString &arg0) 00090 { 00091 AQ_CALL_RET_V(unicodeUriToUri(arg0), QCString); 00092 } 00093 inline bool AQSUriDrag::canDecode(const QMimeSource *arg0) 00094 { 00095 AQ_CALL_RET_V(canDecode(arg0), bool); 00096 } 00097 //@AQ_END_IMP_PUB_SLOTS@ 00098 00099 #endif /* AQSURIDRAG_P_H_ */ 00100 // @AQSOBJECT@