From b8c00e84a560378eee02ece041adaf82a1f90db4 Mon Sep 17 00:00:00 2001 From: Orion Poplawski Date: Sep 22 2016 04:00:11 +0000 Subject: Update to 4.0.5.2 - Drop upstream qt5 patch --- diff --git a/.gitignore b/.gitignore index 4fc2bb7..1ef6b97 100644 --- a/.gitignore +++ b/.gitignore @@ -10,3 +10,4 @@ /x2goclient-4.0.4.0.tar.gz /x2goclient-4.0.5.0.tar.gz /x2goclient-4.0.5.1.tar.gz +/x2goclient-4.0.5.2.tar.gz diff --git a/sources b/sources index f88dc18..dab70cd 100644 --- a/sources +++ b/sources @@ -1 +1 @@ -08ff4bd5d40a9ce011be4c56ac5ce296 x2goclient-4.0.5.1.tar.gz +f931ba4f855011ff3b2328e4c0d287c0 x2goclient-4.0.5.2.tar.gz diff --git a/x2goclient-qt5.patch b/x2goclient-qt5.patch deleted file mode 100644 index 3fa986e..0000000 --- a/x2goclient-qt5.patch +++ /dev/null @@ -1,742 +0,0 @@ -diff --git a/src/SVGFrame.cpp b/src/SVGFrame.cpp -index cb17930..268b037 100644 ---- a/src/SVGFrame.cpp -+++ b/src/SVGFrame.cpp -@@ -26,7 +26,7 @@ - - - SVGFrame::SVGFrame ( QString fname,bool st,QWidget* parent, -- Qt::WFlags f ) :QFrame ( parent,f ) -+ Qt::WindowFlags f ) :QFrame ( parent,f ) - { - empty=false; - #ifdef Q_OS_WIN -@@ -66,7 +66,7 @@ SVGFrame::SVGFrame ( QString fname,bool st,QWidget* parent, - } - - SVGFrame::SVGFrame ( QWidget* parent, -- Qt::WFlags f ) :QFrame ( parent,f ) -+ Qt::WindowFlags f ) :QFrame ( parent,f ) - { - repaint=false; - empty=true; -diff --git a/src/SVGFrame.h b/src/SVGFrame.h -index 1c6fe18..f9d9998 100644 ---- a/src/SVGFrame.h -+++ b/src/SVGFrame.h -@@ -28,8 +28,8 @@ class SVGFrame: public QFrame - - Q_OBJECT - public: -- SVGFrame ( QString fname, bool st, QWidget* parent=0, Qt::WFlags f=0 ); -- SVGFrame ( QWidget* parent=0, Qt::WFlags f=0 ); -+ SVGFrame ( QString fname, bool st, QWidget* parent=0, Qt::WindowFlags f=0 ); -+ SVGFrame ( QWidget* parent=0, Qt::WindowFlags f=0 ); - void setRepaintable ( bool val ) - { - repaint=val; -diff --git a/src/configdialog.cpp b/src/configdialog.cpp -index 99cb7ef..2f70a13 100644 ---- a/src/configdialog.cpp -+++ b/src/configdialog.cpp -@@ -46,7 +46,7 @@ - #endif - - --ConfigDialog::ConfigDialog ( QWidget * parent, Qt::WFlags f ) -+ConfigDialog::ConfigDialog ( QWidget * parent, Qt::WindowFlags f ) - : QDialog ( parent,f ) - { - -diff --git a/src/configdialog.h b/src/configdialog.h -index 717f709..e9b6582 100644 ---- a/src/configdialog.h -+++ b/src/configdialog.h -@@ -44,7 +44,7 @@ class ConfigDialog : public QDialog - Q_OBJECT - public: - ConfigDialog ( QWidget * parent, -- Qt::WFlags f = 0 ); -+ Qt::WindowFlags f = 0 ); - ~ConfigDialog(); - #ifdef Q_OS_DARWIN - static QString findXDarwin ( QString& version, -diff --git a/src/cupsprint.cpp b/src/cupsprint.cpp -index 0354bfc..9f42970 100644 ---- a/src/cupsprint.cpp -+++ b/src/cupsprint.cpp -@@ -53,7 +53,7 @@ QString CUPSPrint::getDefaultUserPrinter() - "CUPS/defaultprinter","" ). toString(); - if ( defPrint.length() >0 ) - { -- cups_dest_t *dest = cupsGetDest ( defPrint.toAscii(), -+ cups_dest_t *dest = cupsGetDest ( defPrint.toUtf8(), - 0l, num_dests, dests ); - if ( dest ) - return defPrint; -@@ -77,7 +77,7 @@ bool CUPSPrint::getPrinterInfo ( const QString& printerName, QString& info, - QString& model, printState& state, - QString& stateReason ) - { -- cups_dest_t *dest = cupsGetDest ( printerName.toAscii(), 0l, -+ cups_dest_t *dest = cupsGetDest ( printerName.toUtf8(), 0l, - num_dests, - dests ); - if ( !dest ) -@@ -114,15 +114,15 @@ bool CUPSPrint::getPrinterInfo ( const QString& printerName, QString& info, - bool CUPSPrint::setCurrentPrinter ( QString prn ) - { - currentPrinter=prn; -- QString fl=cupsGetPPD ( prn.toAscii() ); -+ QString fl=cupsGetPPD ( prn.toUtf8() ); - if ( fl.length() <=0 ) - return false; - - if ( ppd ) - ppdClose ( ppd ); - ppd=0l; -- ppd=ppdOpenFile ( fl.toAscii() ); -- unlink ( fl.toAscii() ); -+ ppd=ppdOpenFile ( fl.toUtf8() ); -+ unlink ( fl.toUtf8() ); - if ( ppd==0l ) - return false; - ppdMarkDefaults ( ppd ); -@@ -141,10 +141,10 @@ bool CUPSPrint::getOptionValue ( const QString& option, - { - if ( !ppd ) - return false; -- ppd_choice_t* choice=ppdFindMarkedChoice ( ppd,option.toAscii() ); -+ ppd_choice_t* choice=ppdFindMarkedChoice ( ppd,option.toUtf8() ); - if ( !choice ) - { -- ppd_option_t* opt=ppdFindOption ( ppd,option.toAscii() ); -+ ppd_option_t* opt=ppdFindOption ( ppd,option.toUtf8() ); - if ( !opt ) - return false; - choice=ppdFindChoice ( opt,opt->defchoice ); -@@ -168,7 +168,7 @@ int CUPSPrint::getOptionValues ( const QString& option, - int cur_val=-1; - values.clear(); - descriptions.clear(); -- ppd_option_t* opt=ppdFindOption ( ppd,option.toAscii() ); -+ ppd_option_t* opt=ppdFindOption ( ppd,option.toUtf8() ); - if ( !opt ) - return -1; - for ( int k=0;knum_choices;++k ) -@@ -241,7 +241,7 @@ bool CUPSPrint::setValue ( const QString& option, const QString& value, - QString valueBefore, textBefore; - if ( !getOptionValue ( option,valueBefore,textBefore ) ) - return false; -- ppdMarkOption ( ppd,option.toAscii(),value.toAscii() ); -+ ppdMarkOption ( ppd,option.toUtf8(),value.toUtf8() ); - - if ( conflictsBefore==ppdConflicts ( ppd ) ) - { -@@ -281,7 +281,7 @@ bool CUPSPrint::setValue ( const QString& option, const QString& value, - - - //set previous value -- ppdMarkOption ( ppd,option.toAscii(),valueBefore.toAscii() ); -+ ppdMarkOption ( ppd,option.toUtf8(),valueBefore.toUtf8() ); - return false; - } - -@@ -290,7 +290,7 @@ bool CUPSPrint::getOptionText ( const QString& option, QString& text ) - { - if ( !ppd ) - return false; -- ppd_option_t* opt=ppdFindOption ( ppd,option .toAscii() ); -+ ppd_option_t* opt=ppdFindOption ( ppd,option .toUtf8() ); - if ( !opt ) - return false; - text=QString::fromLocal8Bit ( opt->text ); -@@ -355,7 +355,7 @@ void CUPSPrint::loadUserOptions() - for ( int i=0;i - #include "sessionexplorer.h" - --ExportDialog::ExportDialog ( QString sid,QWidget * par, Qt::WFlags f ) -+ExportDialog::ExportDialog ( QString sid,QWidget * par, Qt::WindowFlags f ) - : QDialog ( par,f ) - { - sessionId=sid; -diff --git a/src/exportdialog.h b/src/exportdialog.h -index 3a9e667..b971fe9 100644 ---- a/src/exportdialog.h -+++ b/src/exportdialog.h -@@ -33,7 +33,7 @@ class ExportDialog : public QDialog - { - Q_OBJECT - public: -- ExportDialog(QString sid,QWidget * par, Qt::WFlags f = 0); -+ ExportDialog(QString sid,QWidget * par, Qt::WindowFlags f = 0); - - ~ExportDialog(); - QString getExport(){return directory;} -diff --git a/src/httpbrokerclient.cpp b/src/httpbrokerclient.cpp -index 2a1c43c..bcb7ef7 100644 ---- a/src/httpbrokerclient.cpp -+++ b/src/httpbrokerclient.cpp -@@ -598,25 +598,49 @@ void HttpBrokerClient::slotSslErrors ( QNetworkReply* netReply, const QList= 0x050000 -+ cert.issuerInfo ( QSslCertificate::CommonName ).join("; ") -+ #else - cert.issuerInfo ( QSslCertificate::CommonName ) -+ #endif - <= 0x050000 -+ cert.issuerInfo ( QSslCertificate::Organization ).join("; ") -+ #else - cert.issuerInfo ( QSslCertificate::Organization ) -+ #endif - <= 0x050000 -+ cert.issuerInfo ( QSslCertificate::OrganizationalUnitName ).join("; ") -+ #else - cert.issuerInfo ( QSslCertificate::OrganizationalUnitName ) -+ #endif - <= 0x050000 -+ cert.subjectInfo ( QSslCertificate::CommonName ).join("; ") -+ #else - cert.subjectInfo ( QSslCertificate::CommonName ) -+ #endif - <= 0x050000 -+ cert.subjectInfo ( QSslCertificate::Organization ).join("; ") -+ #else - cert.subjectInfo ( QSslCertificate::Organization ) -+ #endif - <= 0x050000 -+ cert.subjectInfo ( QSslCertificate::OrganizationalUnitName ).join("; ") -+ #else - cert.subjectInfo ( QSslCertificate::OrganizationalUnitName ) -+ #endif - < - --IMGFrame::IMGFrame(QImage* ,QWidget* parent, Qt::WFlags f) :QFrame(parent,f) -+IMGFrame::IMGFrame(QImage* ,QWidget* parent, Qt::WindowFlags f) :QFrame(parent,f) - { - //setBg(img); - } -diff --git a/src/imgframe.h b/src/imgframe.h -index d894059..1da2fac 100644 ---- a/src/imgframe.h -+++ b/src/imgframe.h -@@ -31,7 +31,7 @@ class IMGFrame : public QFrame - { - Q_OBJECT - public: -- IMGFrame(QImage* img,QWidget* parent=0, Qt::WFlags f=0); -+ IMGFrame(QImage* img,QWidget* parent=0, Qt::WindowFlags f=0); - ~IMGFrame(); - void setBg(QImage* img); - virtual void resizeEvent(QResizeEvent* event); -diff --git a/src/ongetpass.cpp b/src/ongetpass.cpp -index 932db73..fd53a67 100644 ---- a/src/ongetpass.cpp -+++ b/src/ongetpass.cpp -@@ -35,7 +35,9 @@ - #include - #endif - -+#if QT_VERSION < 0x050000 - #include -+#endif - #include - #include - #include -@@ -50,10 +52,12 @@ int x2goMain ( int argc, char *argv[] ) - QApplication app ( argc,argv ); - - #ifndef Q_WS_HILDON -+#if QT_VERSION < 0x050000 - #ifdef Q_OS_LINUX - app.setStyle ( new QPlastiqueStyle() ); - #endif - #endif -+#endif - QStringList args; - if ( argc > 1 ) - args=app.arguments(); -diff --git a/src/onmainwindow.cpp b/src/onmainwindow.cpp -index be4de32..19f081f 100644 ---- a/src/onmainwindow.cpp -+++ b/src/onmainwindow.cpp -@@ -510,7 +510,7 @@ ONMainWindow::ONMainWindow ( QWidget *parent ) :QMainWindow ( parent ) - connect( xineramaTimer, SIGNAL(timeout()), this, SLOT(slotConfigXinerama())); - - x2goInfof(3)<load (filename)) { - *translator = tmp_translator; -- x2goInfof (4) << tr ("Translator: ") + filename.toAscii () + tr (" found."); -+ x2goInfof (4) << tr ("Translator: ") + filename.toUtf8 () + tr (" found."); - return (true); - } - else { -- x2goWarningf (1) << tr ("Can't load translator: ") + filename.toAscii (); -+ x2goWarningf (1) << tr ("Can't load translator: ") + filename.toUtf8 (); - return (false); - } - #else /* QT_VERSION < 0x040800 */ -@@ -617,13 +617,13 @@ bool ONMainWindow::get_translator (QString file_name_start, QTranslator **transl - - if (tmp_translator->load (load_filename)) { - /* Some translation successfully loaded. That's good enough. */ -- x2goInfof (4) << tr ("Translator: ") + load_filename.toAscii () + tr (" found."); -+ x2goInfof (4) << tr ("Translator: ") + load_filename.toUtf8 () + tr (" found."); - translator_found = true; - *translator = tmp_translator; - break; - } - else { -- x2goWarningf (1) << tr ("Non-fatal: can't load translator: ") + load_filename.toAscii (); -+ x2goWarningf (1) << tr ("Non-fatal: can't load translator: ") + load_filename.toUtf8 (); - x2goWarningf (1) << tr ("Trying to load language with lower preference, if existent."); - } - } -@@ -2787,11 +2787,11 @@ SshMasterConnection* ONMainWindow::startSshConnection ( QString host, QString po - #ifndef Q_OS_WIN - QStringList args=sshEnv[i].split ( "=" ); - x2goDebug<<"Setting ENV " + args[0] + tr(" to ") + args[1]; -- setenv ( args[0].toAscii(),args[1].toAscii(),1 ); -+ setenv ( args[0].toUtf8(),args[1].toUtf8(),1 ); - #else - x2goDebug<<"Set ENV: "<")==-1) - { -- pic+=QByteArray::fromBase64(line.toAscii()); -+ pic+=QByteArray::fromBase64(line.toUtf8()); - line=lines[++i]; -- if (QString(QByteArray::fromBase64(line.toAscii())).indexOf("",Qt::CaseInsensitive)!=-1) -+ if (QString(QByteArray::fromBase64(line.toUtf8())).indexOf("",Qt::CaseInsensitive)!=-1) - { - isSvg=true; - } -@@ -8071,7 +8071,7 @@ void ONMainWindow::slotCopyKey ( bool result, QString output, int pid) - } - else - { -- QString printout = tr( "Connection failed: ") + output.toAscii(); -+ QString printout = tr( "Connection failed: ") + output.toUtf8(); - - if ( output.indexOf ( "publickey,password" ) !=-1 ) - x2goErrorf(11)<< tr( "Connection failed: ") + output + tr(" - Wrong password."); -@@ -11904,7 +11904,7 @@ void ONMainWindow::printSshDError_noHostPubKey() - - "
    " - "
  • Open a Terminal Window (Applications -> Utilities -> Terminal)
  • " -- "
  • Run this command: ssh -p " + clientSshPort.toAscii () -+ "
  • Run this command: ssh -p " + clientSshPort.toUtf8 () - + " localhost
  • " - "
  • You do not need to login. Just quit the Terminal application " - "via Cmd + Q
  • " -@@ -12392,13 +12392,13 @@ void ONMainWindow::doPluginInit() - - QString path=getenv ( "PATH" ); - path=clientDir+":"+pluginDir+":"+path; -- setenv ( "PATH",path.toAscii (),1 ); -+ setenv ( "PATH",path.toUtf8 (),1 ); - - path=getenv ( "LD_LIBRARY_PATH" ); - path=clientDir+":"+pluginDir+":"+path; -- setenv ( "LD_LIBRARY_PATH",path.toAscii () ,1 ); -+ setenv ( "LD_LIBRARY_PATH",path.toUtf8 () ,1 ); - -- setenv ( "X2GO_LIB",clientDir.toAscii () ,1 ); -+ setenv ( "X2GO_LIB",clientDir.toUtf8 () ,1 ); - - QFile::setPermissions ( - clientDir+"/x2goclient", -diff --git a/src/onmainwindow_privat.h b/src/onmainwindow_privat.h -index 3a0f087..d36e4be 100644 ---- a/src/onmainwindow_privat.h -+++ b/src/onmainwindow_privat.h -@@ -67,10 +67,14 @@ - #include - #include - #include -+#if QT_VERSION < 0x050000 - #include -+#endif - #include - #include -+#if QT_VERSION < 0x050000 - #include -+#endif - #include "imgframe.h" - #include - #include "clicklineedit.h" -@@ -149,7 +153,11 @@ - #endif - - #ifdef Q_OS_LINUX -+#if QT_VERSION < 0x050000 - #include -+#else -+#include -+#endif - #include - #include - #endif -diff --git a/src/sessionbutton.cpp b/src/sessionbutton.cpp -index 92771fb..710a9dd 100644 ---- a/src/sessionbutton.cpp -+++ b/src/sessionbutton.cpp -@@ -322,13 +322,13 @@ void SessionButton::redraw() - sessIcon = expandHome(sessIcon); - QPixmap* pix; - -- x2goDebug << "Creating QPixmap with session icon: " << sessIcon.toAscii () << "."; -+ x2goDebug << "Creating QPixmap with session icon: " << sessIcon.toUtf8 () << "."; - if (!par->brokerMode || sessIcon == ":/img/icons/128x128/x2gosession.png") - pix=new QPixmap( sessIcon ); - else - { - pix=new QPixmap; -- pix->loadFromData(QByteArray::fromBase64(sessIcon.toAscii())); -+ pix->loadFromData(QByteArray::fromBase64(sessIcon.toUtf8())); - } - if ( !par->retMiniMode() ) - icon->setPixmap ( pix->scaled ( 64,64,Qt::IgnoreAspectRatio, -diff --git a/src/sessionexplorer.cpp b/src/sessionexplorer.cpp -index 219234f..973d8bf 100644 ---- a/src/sessionexplorer.cpp -+++ b/src/sessionexplorer.cpp -@@ -189,8 +189,13 @@ void SessionExplorer::slotCreateDesktopIcon ( SessionButton* bt ) - - #ifndef Q_OS_WIN - QFile file ( -+#if QT_VERSION < 0x050000 - QDesktopServices::storageLocation ( - QDesktopServices::DesktopLocation ) +"/"+name+".desktop" ); -+#else -+ QStandardPaths::writableLocation( -+ QStandardPaths::DesktopLocation) +"/"+name+".desktop" ); -+#endif - if ( !file.open ( QIODevice::WriteOnly | QIODevice::Text ) ) - return; - -diff --git a/src/sessionmanagedialog.cpp b/src/sessionmanagedialog.cpp -index 8b39316..0f7d44b 100644 ---- a/src/sessionmanagedialog.cpp -+++ b/src/sessionmanagedialog.cpp -@@ -35,7 +35,7 @@ - #define SESSIONIDROLE Qt::UserRole+2 - - SessionManageDialog::SessionManageDialog ( QWidget * parent, -- bool onlyCreateIcon, Qt::WFlags f ) -+ bool onlyCreateIcon, Qt::WindowFlags f ) - : QDialog ( parent, f ) - { - QVBoxLayout* ml=new QVBoxLayout ( this ); -diff --git a/src/sessionmanagedialog.h b/src/sessionmanagedialog.h -index 0428797..3ce7cd7 100644 ---- a/src/sessionmanagedialog.h -+++ b/src/sessionmanagedialog.h -@@ -35,7 +35,7 @@ class SessionManageDialog : public QDialog - public: - SessionManageDialog ( QWidget * parent, - bool onlyCreateIcon=false, -- Qt::WFlags f=0 ); -+ Qt::WindowFlags f=0 ); - ~SessionManageDialog(); - void loadSessions(); - private: -diff --git a/src/sshmasterconnection.cpp b/src/sshmasterconnection.cpp -index bb69047..cd07806 100644 ---- a/src/sshmasterconnection.cpp -+++ b/src/sshmasterconnection.cpp -@@ -99,7 +99,7 @@ void SshMasterConnection::parseKnownHosts() - - QString keyName=type+"@"+port+":"+hostParts[0]; - -- QByteArray bytes=QByteArray::fromBase64(parts[2].toAscii()); -+ QByteArray bytes=QByteArray::fromBase64(parts[2].toUtf8()); - QStringList fields; - - //key is a set of data fields: -@@ -332,10 +332,10 @@ void SshMasterConnection::checkReverseTunnelConnections() - x2goDebug<<"Connecting to "< - 4.0.5.2-1 +- Update to 4.0.5.2 +- Drop upstream qt5 patch + * Thu Mar 24 2016 Orion Poplawski - 4.0.5.1-1 - Update to 4.0.5.1 - Drop shell and pubkey patch applied upstream