table view
[mdictionary] / src / plugins / xdxf / DownloadDict.h
index bf50c17..c5e3d11 100644 (file)
@@ -72,6 +72,14 @@ public:
         _link = lreg.capturedTexts().at(1);
     }
 
+    DownloadDict(const DownloadDict &dict) {
+       _from = dict.fromLang();
+       _to = dict.toLang();
+       _title = dict.title();
+       _size = dict.size();
+       _link  = dict.link();
+    }
+
     //! \return dictionary source language
     QString fromLang() const {return _from;}
 
@@ -92,10 +100,14 @@ public:
         \return 1 if this is before other
     */
     bool operator <(DownloadDict other) const {
-        if(_from < other.fromLang()) return true;
-        if(_from > other.fromLang()) return false;
-        if(_to < other.toLang()) return true;
-        return false;
+        if(_from < other.fromLang())
+            return true;
+        else if(_from > other.fromLang())
+            return false;
+        else if(_to < other.toLang())
+            return true;
+        else
+            return false;
     }
 
 private: