Changeset 14378
- Timestamp:
- Dec 12, 2014, 11:21:04 PM (8 years ago)
- Location:
- trunk/qt
- Files:
-
- 7 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/qt/freespace-label.cc
r14377 r14378 34 34 connect (&myTimer, SIGNAL(timeout()), this, SLOT(onTimer())); 35 35 36 connect (&mySession, SIGNAL(executed(int64_t, const QString&, struct tr_variant*)),37 this, SLOT(onSessionExecuted(int64_t, const QString&, struct tr_variant*)));36 connect (&mySession, SIGNAL(executed(int64_t, const QString&, tr_variant *)), 37 this, SLOT(onSessionExecuted(int64_t, const QString&, tr_variant *))); 38 38 39 39 setPath (path); … … 69 69 70 70 void 71 FreespaceLabel::onSessionExecuted (int64_t tag, const QString& result, structtr_variant * arguments)71 FreespaceLabel::onSessionExecuted (int64_t tag, const QString& result, tr_variant * arguments) 72 72 { 73 73 Q_UNUSED (result); -
trunk/qt/freespace-label.h
r14241 r14378 19 19 class Session; 20 20 21 extern "C" 22 { 23 struct tr_variant; 24 } 25 21 26 class FreespaceLabel: public QLabel 22 27 { … … 35 40 36 41 private slots: 37 void onSessionExecuted (int64_t tag, const QString& result, structtr_variant * arguments);42 void onSessionExecuted (int64_t tag, const QString& result, tr_variant * arguments); 38 43 void onTimer (); 39 44 }; -
trunk/qt/make-dialog.h
r14241 r14378 81 81 QDialogButtonBox * myNewButtonBox; 82 82 QDialog * myNewDialog; 83 structtr_metainfo_builder * myBuilder;83 tr_metainfo_builder * myBuilder; 84 84 85 85 protected: -
trunk/qt/prefs.h
r14370 r14378 147 147 QString myConfigDir; 148 148 mutable QVariant myValues[PREFS_COUNT]; 149 void initDefaults ( struct tr_variant*);149 void initDefaults (tr_variant *); 150 150 151 151 public: -
trunk/qt/session.cc
r14377 r14378 90 90 91 91 void 92 FileAdded::executed (int64_t tag, const QString& result, structtr_variant * arguments)92 FileAdded::executed (int64_t tag, const QString& result, tr_variant * arguments) 93 93 { 94 94 Q_UNUSED (arguments); … … 701 701 702 702 void 703 Session::localSessionCallback (tr_session * s, structevbuffer * json, void * vself)703 Session::localSessionCallback (tr_session * s, evbuffer * json, void * vself) 704 704 { 705 705 Q_UNUSED (s); … … 921 921 922 922 void 923 Session::updateStats (tr_variant * d, structtr_session_stats * stats)923 Session::updateStats (tr_variant * d, tr_session_stats * stats) 924 924 { 925 925 int64_t i; … … 1107 1107 if (trashOriginal && addMe.type == AddData::FILENAME) 1108 1108 fileAdded->setFileToDelete (addMe.filename); 1109 connect (this, SIGNAL (executed (int64_t, QString, structtr_variant *)),1110 fileAdded, SLOT (executed (int64_t, QString, structtr_variant *)));1109 connect (this, SIGNAL (executed (int64_t, QString, tr_variant *)), 1110 fileAdded, SLOT (executed (int64_t, QString, tr_variant *))); 1111 1111 1112 1112 exec (&top); -
trunk/qt/session.h
r14349 r14378 46 46 47 47 public slots: 48 void executed (int64_t tag, const QString& result, structtr_variant * arguments);48 void executed (int64_t tag, const QString& result, tr_variant * arguments); 49 49 50 50 private: … … 71 71 public: 72 72 const QUrl& getRemoteUrl () const { return myUrl; } 73 const structtr_session_stats& getStats () const { return myStats; }74 const structtr_session_stats& getCumulativeStats () const { return myCumulativeStats; }73 const tr_session_stats& getStats () const { return myStats; } 74 const tr_session_stats& getCumulativeStats () const { return myCumulativeStats; } 75 75 const QString& sessionVersion () const { return mySessionVersion; } 76 76 … … 91 91 92 92 private: 93 void updateStats ( structtr_variant * args);94 void updateInfo ( structtr_variant * args);93 void updateStats (tr_variant * args); 94 void updateInfo (tr_variant * args); 95 95 void parseResponse (const char * json, size_t len); 96 static void localSessionCallback (tr_session *, structevbuffer *, void *);96 static void localSessionCallback (tr_session *, evbuffer *, void *); 97 97 98 98 public: 99 99 void exec (const char * json); 100 void exec (const structtr_variant * request);100 void exec (const tr_variant * request); 101 101 102 102 public: … … 107 107 void pumpRequests (); 108 108 void sendTorrentRequest (const char * request, const QSet<int>& torrentIds); 109 static void updateStats ( struct tr_variant * d, structtr_session_stats * stats);109 static void updateStats (tr_variant * d, tr_session_stats * stats); 110 110 void refreshTorrents (const QSet<int>& torrentIds); 111 111 QNetworkAccessManager * networkAccessManager (); … … 152 152 signals: 153 153 void responseReceived (const QByteArray& json); 154 void executed (int64_t tag, const QString& result, structtr_variant * arguments);154 void executed (int64_t tag, const QString& result, tr_variant * arguments); 155 155 void sourceChanged (); 156 156 void portTested (bool isOpen); … … 158 158 void sessionUpdated (); 159 159 void blocklistUpdated (int); 160 void torrentsUpdated ( structtr_variant * torrentList, bool completeList);161 void torrentsRemoved ( structtr_variant * torrentList);160 void torrentsUpdated (tr_variant * torrentList, bool completeList); 161 void torrentsRemoved (tr_variant * torrentList); 162 162 void dataReadProgress (); 163 163 void dataSendProgress (); … … 176 176 QUrl myUrl; 177 177 QNetworkAccessManager * myNAM; 178 structtr_session_stats myStats;179 structtr_session_stats myCumulativeStats;178 tr_session_stats myStats; 179 tr_session_stats myCumulativeStats; 180 180 QString mySessionVersion; 181 181 }; -
trunk/qt/stats-dialog.cc
r14377 r14378 80 80 StatsDialog::updateStats () 81 81 { 82 const structtr_session_stats& current (mySession.getStats ());83 const structtr_session_stats& total (mySession.getCumulativeStats ());82 const tr_session_stats& current (mySession.getStats ()); 83 const tr_session_stats& total (mySession.getCumulativeStats ()); 84 84 85 85 myCurrentUp->setText (Formatter::sizeToString (current.uploadedBytes));
Note: See TracChangeset
for help on using the changeset viewer.