Changeset 14378


Ignore:
Timestamp:
Dec 12, 2014, 11:21:04 PM (8 years ago)
Author:
mikedld
Message:

Remove redundant "struct" keyword use in C++ code (Qt client)

Location:
trunk/qt
Files:
7 edited

Legend:

Unmodified
Added
Removed
  • trunk/qt/freespace-label.cc

    r14377 r14378  
    3434  connect (&myTimer, SIGNAL(timeout()), this, SLOT(onTimer()));
    3535
    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 *)));
    3838
    3939  setPath (path);
     
    6969
    7070void
    71 FreespaceLabel::onSessionExecuted (int64_t tag, const QString& result, struct tr_variant * arguments)
     71FreespaceLabel::onSessionExecuted (int64_t tag, const QString& result, tr_variant * arguments)
    7272{
    7373  Q_UNUSED (result);
  • trunk/qt/freespace-label.h

    r14241 r14378  
    1919class Session;
    2020
     21extern "C"
     22{
     23  struct tr_variant;
     24}
     25
    2126class FreespaceLabel: public QLabel
    2227{
     
    3540
    3641  private slots:
    37     void onSessionExecuted (int64_t tag, const QString& result, struct tr_variant * arguments);
     42    void onSessionExecuted (int64_t tag, const QString& result, tr_variant * arguments);
    3843    void onTimer ();
    3944};
  • trunk/qt/make-dialog.h

    r14241 r14378  
    8181    QDialogButtonBox * myNewButtonBox;
    8282    QDialog * myNewDialog;
    83     struct tr_metainfo_builder * myBuilder;
     83    tr_metainfo_builder * myBuilder;
    8484
    8585  protected:
  • trunk/qt/prefs.h

    r14370 r14378  
    147147    QString myConfigDir;
    148148    mutable QVariant myValues[PREFS_COUNT];
    149     void initDefaults (struct tr_variant*);
     149    void initDefaults (tr_variant *);
    150150
    151151  public:
  • trunk/qt/session.cc

    r14377 r14378  
    9090
    9191void
    92 FileAdded::executed (int64_t tag, const QString& result, struct tr_variant * arguments)
     92FileAdded::executed (int64_t tag, const QString& result, tr_variant * arguments)
    9393{
    9494  Q_UNUSED (arguments);
     
    701701
    702702void
    703 Session::localSessionCallback (tr_session * s, struct evbuffer * json, void * vself)
     703Session::localSessionCallback (tr_session * s, evbuffer * json, void * vself)
    704704{
    705705  Q_UNUSED (s);
     
    921921
    922922void
    923 Session::updateStats (tr_variant * d, struct tr_session_stats * stats)
     923Session::updateStats (tr_variant * d, tr_session_stats * stats)
    924924{
    925925  int64_t i;
     
    11071107  if (trashOriginal && addMe.type == AddData::FILENAME)
    11081108    fileAdded->setFileToDelete (addMe.filename);
    1109   connect (this, SIGNAL (executed (int64_t, QString, struct tr_variant *)),
    1110            fileAdded, SLOT (executed (int64_t, QString, struct tr_variant *)));
     1109  connect (this, SIGNAL (executed (int64_t, QString, tr_variant *)),
     1110           fileAdded, SLOT (executed (int64_t, QString, tr_variant *)));
    11111111
    11121112  exec (&top);
  • trunk/qt/session.h

    r14349 r14378  
    4646
    4747  public slots:
    48     void executed (int64_t tag, const QString& result, struct tr_variant * arguments);
     48    void executed (int64_t tag, const QString& result, tr_variant * arguments);
    4949
    5050  private:
     
    7171  public:
    7272    const QUrl& getRemoteUrl () const { return myUrl; }
    73     const struct tr_session_stats& getStats () const { return myStats; }
    74     const struct tr_session_stats& getCumulativeStats () const { return myCumulativeStats; }
     73    const tr_session_stats& getStats () const { return myStats; }
     74    const tr_session_stats& getCumulativeStats () const { return myCumulativeStats; }
    7575    const QString& sessionVersion () const { return mySessionVersion; }
    7676
     
    9191
    9292  private:
    93     void updateStats (struct tr_variant * args);
    94     void updateInfo (struct tr_variant * args);
     93    void updateStats (tr_variant * args);
     94    void updateInfo (tr_variant * args);
    9595    void parseResponse (const char * json, size_t len);
    96     static void localSessionCallback (tr_session *, struct evbuffer *, void *);
     96    static void localSessionCallback (tr_session *, evbuffer *, void *);
    9797
    9898  public:
    9999    void exec (const char * json);
    100     void exec (const struct tr_variant * request);
     100    void exec (const tr_variant * request);
    101101
    102102  public:
     
    107107    void pumpRequests ();
    108108    void sendTorrentRequest (const char * request, const QSet<int>& torrentIds);
    109     static void updateStats (struct tr_variant * d, struct tr_session_stats * stats);
     109    static void updateStats (tr_variant * d, tr_session_stats * stats);
    110110    void refreshTorrents (const QSet<int>& torrentIds);
    111111    QNetworkAccessManager * networkAccessManager ();
     
    152152  signals:
    153153    void responseReceived (const QByteArray& json);
    154     void executed (int64_t tag, const QString& result, struct tr_variant * arguments);
     154    void executed (int64_t tag, const QString& result, tr_variant * arguments);
    155155    void sourceChanged ();
    156156    void portTested (bool isOpen);
     
    158158    void sessionUpdated ();
    159159    void blocklistUpdated (int);
    160     void torrentsUpdated (struct tr_variant * torrentList, bool completeList);
    161     void torrentsRemoved (struct tr_variant * torrentList);
     160    void torrentsUpdated (tr_variant * torrentList, bool completeList);
     161    void torrentsRemoved (tr_variant * torrentList);
    162162    void dataReadProgress ();
    163163    void dataSendProgress ();
     
    176176    QUrl myUrl;
    177177    QNetworkAccessManager * myNAM;
    178     struct tr_session_stats myStats;
    179     struct tr_session_stats myCumulativeStats;
     178    tr_session_stats myStats;
     179    tr_session_stats myCumulativeStats;
    180180    QString mySessionVersion;
    181181};
  • trunk/qt/stats-dialog.cc

    r14377 r14378  
    8080StatsDialog::updateStats ()
    8181{
    82   const struct tr_session_stats& current (mySession.getStats ());
    83   const struct tr_session_stats& total (mySession.getCumulativeStats ());
     82  const tr_session_stats& current (mySession.getStats ());
     83  const tr_session_stats& total (mySession.getCumulativeStats ());
    8484
    8585  myCurrentUp->setText (Formatter::sizeToString (current.uploadedBytes));
Note: See TracChangeset for help on using the changeset viewer.