Changeset 77435 in vbox
- Timestamp:
- Feb 22, 2019 3:25:52 PM (6 years ago)
- svn:sync-xref-src-repo-rev:
- 128998
- Location:
- trunk/src/VBox/Frontends/VirtualBox/src/globals
- Files:
-
- 2 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/src/VBox/Frontends/VirtualBox/src/globals/UITextTable.cpp
r77432 r77435 16 16 */ 17 17 18 /* Qt includes: */19 #include <QAccessibleObject>20 #include <QPainter>21 #include <QTextLayout>22 #include <QApplication>23 #include <QFontMetrics>24 #include <QGraphicsSceneHoverEvent>25 26 18 /* GUI includes: */ 27 19 #include "UITextTable.h" 28 #include "UIRichTextString.h"29 #include "VBoxGlobal.h"30 20 31 /* Other VBox includes: */ 32 #include <iprt/assert.h> 21 22 UITextTableLine::UITextTableLine(const QString &str1, const QString &str2, QObject *pParent /* = 0 */) 23 : QObject(pParent) 24 , m_str1(str1) 25 , m_str2(str2) 26 {} 27 28 UITextTableLine::UITextTableLine(const UITextTableLine &other) 29 : QObject(other.parent()) 30 , m_str1(other.string1()) 31 , m_str2(other.string2()) 32 {} 33 34 UITextTableLine &UITextTableLine::operator=(const UITextTableLine &other) 35 { 36 setParent(other.parent()); 37 set1(other.string1()); 38 set2(other.string2()); 39 return *this; 40 } 41 42 bool UITextTableLine::operator==(const UITextTableLine &other) const 43 { 44 return string1() == other.string1() 45 && string2() == other.string2(); 46 } -
trunk/src/VBox/Frontends/VirtualBox/src/globals/UITextTable.h
r77433 r77435 22 22 #endif 23 23 24 /* Qt includes: */ 25 #include <QObject> 26 #include <QString> 27 24 28 /* GUI includes: */ 25 #include "QIGraphicsWidget.h" 26 27 /* Forward declarations: */ 28 class QTextLayout; 29 29 #include "UILibraryDefs.h" 30 30 31 31 /** QObject extension used as an … … 40 40 * @param str1 Brings the 1st table string. 41 41 * @param str2 Brings the 2nd table string. */ 42 UITextTableLine(const QString &str1, const QString &str2, QObject *pParent = 0) 43 : QObject(pParent) 44 , m_str1(str1) 45 , m_str2(str2) 46 {} 42 UITextTableLine(const QString &str1, const QString &str2, QObject *pParent = 0); 47 43 48 44 /** Constructs text-table line on the basis of passed @a other. */ 49 UITextTableLine(const UITextTableLine &other) 50 : QObject(other.parent()) 51 , m_str1(other.string1()) 52 , m_str2(other.string2()) 53 {} 45 UITextTableLine(const UITextTableLine &other); 54 46 55 47 /** Assigns @a other to this. */ 56 UITextTableLine &operator=(const UITextTableLine &other) 57 { 58 setParent(other.parent()); 59 set1(other.string1()); 60 set2(other.string2()); 61 return *this; 62 } 48 UITextTableLine &operator=(const UITextTableLine &other); 63 49 64 50 /** Compares @a other to this. */ 65 bool operator==(const UITextTableLine &other) const 66 { 67 return string1() == other.string1() 68 && string2() == other.string2(); 69 } 51 bool operator==(const UITextTableLine &other) const; 70 52 71 53 /** Defines 1st table @a strString. */ … … 91 73 Q_DECLARE_METATYPE(UITextTable); 92 74 93 94 75 #endif /* !FEQT_INCLUDED_SRC_globals_UITextTable_h */
Note:
See TracChangeset
for help on using the changeset viewer.