Changeset 137 for smplayer/vendor/current/src/basegui.cpp
- Timestamp:
- Dec 3, 2012, 5:29:00 PM (13 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
smplayer/vendor/current/src/basegui.cpp
r133 r137 745 745 this, SLOT(helpCheckUpdates()) ); 746 746 747 donateAct = new MyAction( this, "donate" );748 connect( donateAct, SIGNAL(triggered()),749 this, SLOT(help Donate()) );747 showConfigAct = new MyAction( this, "show_config" ); 748 connect( showConfigAct, SIGNAL(triggered()), 749 this, SLOT(helpShowConfig()) ); 750 750 751 751 aboutQtAct = new MyAction( this, "about_qt" ); … … 955 955 channelsSurroundAct = new MyActionGroupItem(this, channelsGroup, "channels_surround", MediaSettings::ChSurround); 956 956 channelsFull51Act = new MyActionGroupItem(this, channelsGroup, "channels_ful51", MediaSettings::ChFull51); 957 channelsFull61Act = new MyActionGroupItem(this, channelsGroup, "channels_ful61", MediaSettings::ChFull61); 958 channelsFull71Act = new MyActionGroupItem(this, channelsGroup, "channels_ful71", MediaSettings::ChFull71); 957 959 connect( channelsGroup, SIGNAL(activated(int)), 958 960 core, SLOT(setAudioChannels(int)) ); … … 1556 1558 showCLOptionsAct->change( Images::icon("cl_help"), tr("&Command line options") ); 1557 1559 showCheckUpdatesAct->change( Images::icon("check_updates"), tr("Check for &updates") ); 1558 donateAct->change( Images::icon("donate"), tr("&Donate") );1560 showConfigAct->change( Images::icon("show_config"), tr("&Open configuration folder") ); 1559 1561 aboutQtAct->change( QPixmap(":/icons-png/qt.png"), tr("About &Qt") ); 1560 1562 aboutThisAct->change( Images::icon("logo_small"), tr("About &SMPlayer") ); … … 1761 1763 channelsSurroundAct->change( tr("&4.0 Surround") ); 1762 1764 channelsFull51Act->change( tr("&5.1 Surround") ); 1765 channelsFull61Act->change( tr("&6.1 Surround") ); 1766 channelsFull71Act->change( tr("&7.1 Surround") ); 1763 1767 1764 1768 stereoAct->change( tr("&Stereo") ); … … 1969 1973 #endif 1970 1974 1971 Q HBoxLayout * layout = new QHBoxLayout;1975 QVBoxLayout * layout = new QVBoxLayout; 1972 1976 layout->setSpacing(0); 1973 1977 layout->setMargin(0); … … 1996 2000 connect( mplayerwindow, SIGNAL(mouseMoved(QPoint)), 1997 2001 this, SLOT(checkMousePos(QPoint)) ); 2002 connect( mplayerwindow, SIGNAL(mouseMovedDiff(QPoint)), 2003 this, SLOT(moveWindow(QPoint))); 1998 2004 } 1999 2005 … … 2484 2490 helpMenu->addAction(showCLOptionsAct); 2485 2491 helpMenu->addAction(showCheckUpdatesAct); 2486 helpMenu->addAction( donateAct);2492 helpMenu->addAction(showConfigAct); 2487 2493 helpMenu->addSeparator(); 2488 2494 helpMenu->addAction(aboutQtAct); … … 3695 3701 } 3696 3702 3697 void BaseGui::helpDonate() { 3698 QMessageBox d(QMessageBox::NoIcon, tr("Donate"), 3699 tr("If you like SMPlayer, a really good way to support it is by sending a donation, even the smallest one is highly appreciated.") + "<br>" + 3700 tr("You can send your donation using %1.").arg("<a href=\"https://sourceforge.net/donate/index.php?group_id=185512\">"+tr("this form")), 3701 QMessageBox::Ok, this); 3702 d.setIconPixmap( Images::icon("logo", 64) ); 3703 d.exec(); 3703 void BaseGui::helpShowConfig() { 3704 QDesktopServices::openUrl(QUrl::fromLocalFile(Paths::configPath())); 3704 3705 } 3705 3706 … … 4170 4171 void BaseGui::playlistHasFinished() { 4171 4172 qDebug("BaseGui::playlistHasFinished"); 4173 core->stop(); 4174 4172 4175 exitFullscreenOnStop(); 4173 4176 … … 4471 4474 QString styleSheet = QLatin1String(file.readAll()); 4472 4475 4476 QDir current = QDir::current(); 4477 QString td = Images::themesDirectory(); 4478 QString relativePath = current.relativeFilePath(td); 4479 styleSheet.replace(QRegExp("url\\s*\\(\\s*([^\\);]+)\\s*\\)", Qt::CaseSensitive, QRegExp::RegExp2), 4480 QString("url(%1\\1)").arg(relativePath + "/")); 4481 qDebug("styeSheet: %s", styleSheet.toUtf8().constData()); 4482 4473 4483 qApp->setStyleSheet(styleSheet); 4474 4484 } … … 4516 4526 } 4517 4527 4528 void BaseGui::moveWindow(QPoint diff) { 4529 if (pref->fullscreen || isMaximized()) { 4530 return; 4531 } 4532 move(pos() + diff); 4533 } 4518 4534 4519 4535 void BaseGui::showEvent( QShowEvent * ) {
Note:
See TracChangeset
for help on using the changeset viewer.