Changeset 12217 in vbox
- Timestamp:
- Sep 8, 2008 11:37:21 AM (16 years ago)
- Location:
- trunk/src/VBox/Frontends/VirtualBox4
- Files:
-
- 2 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/src/VBox/Frontends/VirtualBox4/include/VBoxFilePathSelectorWidget.h
r11845 r12217 76 76 void copyToClipboard(); 77 77 void refreshText(); 78 void setPathInternal (const QString &aText); 78 79 79 80 private: … … 94 95 bool mIsEditableMode; 95 96 bool mIsMouseAwaited; 97 98 bool mModified; 96 99 }; 97 100 -
trunk/src/VBox/Frontends/VirtualBox4/src/VBoxFilePathSelectorWidget.cpp
r12013 r12217 64 64 , mIsEditableMode (false) 65 65 , mIsMouseAwaited (false) 66 , mModified (false) 66 67 { 67 68 /* Populate items */ … … 88 89 /* Setup connections */ 89 90 connect (lineEdit(), SIGNAL (textEdited (const QString &)), 90 this, SLOT (setPath (const QString &)));91 this, SLOT (setPathInternal (const QString &))); 91 92 connect (this, SIGNAL (activated (int)), this, SLOT (onActivated (int))); 92 93 connect (mCopyAction, SIGNAL (triggered (bool)), this, SLOT (copyToClipboard())); … … 133 134 bool VBoxFilePathSelectorWidget::isModified() const 134 135 { 135 return true;136 return mModified; 136 137 } 137 138 … … 272 273 case ResetId: 273 274 { 274 setPath (QString::null);275 setPathInternal (QString::null); 275 276 break; 276 277 } … … 307 308 308 309 path.remove (QRegExp ("[\\\\/]$")); 309 setPath (path);310 setPathInternal (path); 310 311 } 311 312 … … 459 460 } 460 461 462 void VBoxFilePathSelectorWidget::setPathInternal (const QString &aText) 463 { 464 QString oldPath = mPath; 465 setPath (aText); 466 if (mPath != oldPath) 467 mModified = true; 468 } 469
Note:
See TracChangeset
for help on using the changeset viewer.