This is an automated email from the git hooks/post-receive script. x2go pushed a change to branch master in repository x2goclient. from 607c333 destroy unused SSH sessions for LDAP authentication. new c92b679 src/sshmasterconnection.cpp: stop libssh/OpenSSL from querying for a passphrase if started with a controlling terminal. new 294ac0b x2goclient.pro: remove plugin references. new d3d4413 x2goclient.spec: remove plugin references. new 0fa3356 misc: change http:// to https:// where appropriate, but in actual code and translation files for now. new 4f70ddf debian/rules: remove plugin references. new bd2436f debian/control: convert plugin packages to dummy transitional packages with no dependencies, remove other plugin references. new 84fc6e4 Makefile: remove plugin references. new dd26e30 Makefile: remove x2goclient_*.qm files in clean rule. new df16a01 debian/rules: remove x2goclient_*.qm files removal. new 9274e2c x2gobrowserplugin-2.4_1/: remove. new cb360e1 provider/: remove. new 535ce57 INSTALL: remove plugin references. new 53f656a debian/x2goplugin{,-provider}.install: clear out. new 51738fb debian/{x2goplugin.dirs,x2goplugin-provider.dirs,x2goplugin-provider.links,x2goplugin-provider.post*}: remove. new 1374ac4 {{build,config}_win_plugin.bat,config_linux_{,static_}plugin.sh}: remove. new e7d4e13 config_win.bat: remove plugin references. new 58a7ad4 debian/copyright: remove plugin references. new 83b8a9c src/{configdialog.cpp,onmainwindow{.cpp,{,_privat}.h}}: remove plugin references. The 18 revisions listed above as "new" are entirely new to this repository and will be described in separate emails. The revisions listed as "adds" were already present in the repository and have only been added to this reference. Summary of changes: COPYRIGHT.x2go-logos | 2 +- INSTALL | 20 +- LICENSE | 6 +- Makefile | 50 +- README.i18n | 2 +- build_win_plugin.bat | 17 - config_linux_plugin.sh | 7 - config_linux_static_plugin.sh | 8 - config_win.bat | 1 - config_win_plugin.bat | 8 - debian/changelog | 29 + debian/control | 40 +- debian/copyright | 43 +- debian/rules | 8 +- debian/x2goplugin-provider.dirs | 2 - debian/x2goplugin-provider.install | 2 - debian/x2goplugin-provider.links | 2 - debian/x2goplugin-provider.postinst | 49 - debian/x2goplugin-provider.postrm | 47 - debian/x2goplugin.dirs | 1 - debian/x2goplugin.install | 1 - man/man1/x2goclient.1 | 2 +- nsis/x2goclient.nsi | 4 +- pkg-dmg | 2 +- portable/manifest.u3i | 2 +- provider/etc/x2goplugin-apache.conf | 15 - provider/share/x2goplugin.html | 47 - src/InteractionDialog.cpp | 2 +- src/InteractionDialog.h | 2 +- src/LDAPSession.cpp | 2 +- src/LDAPSession.h | 2 +- src/SVGFrame.cpp | 2 +- src/SVGFrame.h | 2 +- src/appdialog.cpp | 2 +- src/appdialog.h | 2 +- src/brokerpassdlg.cpp | 2 +- src/brokerpassdlg.h | 2 +- src/clicklineedit.cpp | 2 +- src/clicklineedit.h | 2 +- src/configdialog.cpp | 10 +- src/configdialog.h | 2 +- src/configwidget.cpp | 2 +- src/configwidget.h | 2 +- src/connectionwidget.cpp | 2 +- src/connectionwidget.h | 2 +- src/contest.cpp | 2 +- src/contest.h | 2 +- src/cupsprint.cpp | 2 +- src/cupsprint.h | 2 +- src/cupsprintersettingsdialog.cpp | 2 +- src/cupsprintersettingsdialog.h | 2 +- src/cupsprintwidget.cpp | 2 +- src/cupsprintwidget.h | 2 +- src/editconnectiondialog.cpp | 2 +- src/editconnectiondialog.h | 2 +- src/exportdialog.cpp | 2 +- src/exportdialog.h | 2 +- src/folderbutton.cpp | 2 +- src/folderbutton.h | 2 +- src/folderexplorer.cpp | 2 +- src/folderexplorer.h | 2 +- src/helpdialog.cpp | 2 +- src/helpdialog.h | 2 +- src/httpbrokerclient.cpp | 2 +- src/httpbrokerclient.h | 2 +- src/imgframe.cpp | 2 +- src/imgframe.h | 2 +- src/mediawidget.cpp | 2 +- src/mediawidget.h | 2 +- src/non_modal_messagebox.cpp | 2 +- src/non_modal_messagebox.h | 2 +- src/ongetpass.cpp | 2 +- src/ongetpass.h | 2 +- src/onmainwindow.cpp | 413 +---- src/onmainwindow.h | 79 +- src/onmainwindow_privat.h | 9 +- src/printdialog.cpp | 2 +- src/printdialog.h | 2 +- src/printercmddialog.cpp | 2 +- src/printercmddialog.h | 2 +- src/printprocess.cpp | 2 +- src/printprocess.h | 2 +- src/printwidget.cpp | 2 +- src/printwidget.h | 2 +- src/sessionbutton.cpp | 2 +- src/sessionbutton.h | 2 +- src/sessionexplorer.cpp | 2 +- src/sessionexplorer.h | 2 +- src/sessionmanagedialog.cpp | 2 +- src/sessionmanagedialog.h | 2 +- src/sessionwidget.cpp | 2 +- src/sessionwidget.h | 2 +- src/settingswidget.cpp | 2 +- src/settingswidget.h | 2 +- src/sharewidget.cpp | 2 +- src/sharewidget.h | 2 +- src/sshmasterconnection.cpp | 15 +- src/sshmasterconnection.h | 2 +- src/sshprocess.cpp | 2 +- src/sshprocess.h | 2 +- src/userbutton.cpp | 2 +- src/userbutton.h | 2 +- src/version.h | 2 +- src/wapi.cpp | 2 +- src/wapi.h | 2 +- src/x2goclient.cpp | 2 +- src/x2goclientconfig.h | 2 +- src/x2gologdebug.cpp | 2 +- src/x2gologdebug.h | 2 +- src/x2gosettings.cpp | 2 +- src/x2gosettings.h | 2 +- src/x2goutils.cpp | 2 +- src/x2goutils.h | 2 +- src/xsettingswidget.cpp | 2 +- src/xsettingswidget.h | 2 +- x2gobrowserplugin-2.4_1/src/qtbrowserplugin.cpp | 1703 -------------------- x2gobrowserplugin-2.4_1/src/qtbrowserplugin.def | 4 - x2gobrowserplugin-2.4_1/src/qtbrowserplugin.h | 176 -- x2gobrowserplugin-2.4_1/src/qtbrowserplugin.pri | 74 - .../src/qtbrowserplugin_mac.cpp | 560 ------- x2gobrowserplugin-2.4_1/src/qtbrowserplugin_p.h | 94 -- .../src/qtbrowserplugin_win.cpp | 194 --- .../src/qtbrowserplugin_x11.cpp | 150 -- x2gobrowserplugin-2.4_1/src/qtbrowserpluginax.def | 9 - x2gobrowserplugin-2.4_1/src/qtnpapi.h | 555 ------- x2gobrowserplugin-2.4_1/src/res/x2goplugin.rc | 37 - x2goclient.pro | 30 +- x2goclient.spec | 98 +- x2gohelper/x2gohelper.cpp | 2 +- 129 files changed, 179 insertions(+), 4616 deletions(-) delete mode 100755 build_win_plugin.bat delete mode 100755 config_linux_plugin.sh delete mode 100755 config_linux_static_plugin.sh delete mode 100755 config_win_plugin.bat delete mode 100644 debian/x2goplugin-provider.dirs delete mode 100644 debian/x2goplugin-provider.links delete mode 100755 debian/x2goplugin-provider.postinst delete mode 100755 debian/x2goplugin-provider.postrm delete mode 100644 debian/x2goplugin.dirs delete mode 100644 provider/etc/x2goplugin-apache.conf delete mode 100644 provider/share/x2goplugin.html delete mode 100644 x2gobrowserplugin-2.4_1/src/qtbrowserplugin.cpp delete mode 100644 x2gobrowserplugin-2.4_1/src/qtbrowserplugin.def delete mode 100644 x2gobrowserplugin-2.4_1/src/qtbrowserplugin.h delete mode 100644 x2gobrowserplugin-2.4_1/src/qtbrowserplugin.pri delete mode 100644 x2gobrowserplugin-2.4_1/src/qtbrowserplugin_mac.cpp delete mode 100644 x2gobrowserplugin-2.4_1/src/qtbrowserplugin_p.h delete mode 100644 x2gobrowserplugin-2.4_1/src/qtbrowserplugin_win.cpp delete mode 100644 x2gobrowserplugin-2.4_1/src/qtbrowserplugin_x11.cpp delete mode 100644 x2gobrowserplugin-2.4_1/src/qtbrowserpluginax.def delete mode 100644 x2gobrowserplugin-2.4_1/src/qtnpapi.h delete mode 100644 x2gobrowserplugin-2.4_1/src/res/x2goplugin.rc -- Alioth's /home/x2go-admin/maintenancescripts/git/hooks/post-receive-email on /srv/git/code.x2go.org/x2goclient.git
This is an automated email from the git hooks/post-receive script. x2go pushed a commit to branch master in repository x2goclient. commit 294ac0b92f639b49983ef2e4610b2aada4e54333 Author: Mihai Moldovan <ionic@ionic.de> Date: Wed Mar 14 00:58:03 2018 +0100 x2goclient.pro: remove plugin references. --- debian/changelog | 1 + x2goclient.pro | 30 ++++-------------------------- 2 files changed, 5 insertions(+), 26 deletions(-) diff --git a/debian/changelog b/debian/changelog index 2e0f54c..bb2dd99 100644 --- a/debian/changelog +++ b/debian/changelog @@ -30,6 +30,7 @@ x2goclient (4.1.2.0-0x2go1) UNRELEASED; urgency=medium LXQt. Fixes: #1263. - src/sshmasterconnection.cpp: stop libssh/OpenSSL from querying for a passphrase if started with a controlling terminal. + - x2goclient.pro: remove plugin references. -- X2Go Release Manager <git-admin@x2go.org> Thu, 15 Feb 2018 22:01:32 +0100 diff --git a/x2goclient.pro b/x2goclient.pro index 71935e2..f628fa3 100644 --- a/x2goclient.pro +++ b/x2goclient.pro @@ -135,16 +135,10 @@ SOURCES += src/sharewidget.cpp \ LIBS += -lssh -lssh_threads win32:LIBS += -lAdvAPI32 -lshell32 -lUser32 -plugin { - TARGET = x2goplugin -} -else { - RC_FILE = res/x2goclient.rc - SOURCES += src/x2goclient.cpp - TARGET = x2goclient - DEFINES += CFGCLIENT - message("if you want to build x2goplugin you should export X2GO_CLIENT_TARGET=plugin") -} +RC_FILE = res/x2goclient.rc +SOURCES += src/x2goclient.cpp +TARGET = x2goclient +DEFINES += CFGCLIENT !isEmpty(TRANSLATIONS) { isEmpty(QMAKE_LRELEASE) { @@ -250,19 +244,3 @@ greaterThan(QT_MAJOR_VERSION, 4): QT += x11extras QMAKE_CXXFLAGS_DEBUG -= -g QMAKE_CXXFLAGS_DEBUG += -O2 -g3 -ggdb3 -gdwarf-4 - -plugin { - DEFINES += CFGPLUGIN - linux-g++ { - include(x2gobrowserplugin-2.4_1/src/qtbrowserplugin.pri) - } - linux-g++-64 { - include(x2gobrowserplugin-2.4_1/src/qtbrowserplugin.pri) - } - win32-* { - DEFINES += QT_NODLL - CONFIG += qaxserver - include(x2gobrowserplugin-2.4_1/src/qtbrowserplugin.pri) - } - RC_FILE = x2gobrowserplugin-2.4_1/src/res/x2goplugin.rc -} -- Alioth's /home/x2go-admin/maintenancescripts/git/hooks/post-receive-email on /srv/git/code.x2go.org/x2goclient.git
This is an automated email from the git hooks/post-receive script. x2go pushed a commit to branch master in repository x2goclient. commit d3d4413380c8ced1a5464ae5ea95bdd7d7a4602d Author: Mihai Moldovan <ionic@ionic.de> Date: Wed Mar 14 01:04:54 2018 +0100 x2goclient.spec: remove plugin references. --- debian/changelog | 2 ++ x2goclient.spec | 94 ++------------------------------------------------------ 2 files changed, 5 insertions(+), 91 deletions(-) diff --git a/debian/changelog b/debian/changelog index bb2dd99..a15229a 100644 --- a/debian/changelog +++ b/debian/changelog @@ -31,6 +31,8 @@ x2goclient (4.1.2.0-0x2go1) UNRELEASED; urgency=medium - src/sshmasterconnection.cpp: stop libssh/OpenSSL from querying for a passphrase if started with a controlling terminal. - x2goclient.pro: remove plugin references. + * x2goclient.spec: + - Remove plugin references. -- X2Go Release Manager <git-admin@x2go.org> Thu, 15 Feb 2018 22:01:32 +0100 diff --git a/x2goclient.spec b/x2goclient.spec index 248720b..98800d2 100644 --- a/x2goclient.spec +++ b/x2goclient.spec @@ -33,10 +33,6 @@ BuildRequires: qt-devel BuildRequires: openldap-devel %endif -%if 0%{?fedora} >= 19 || 0%{?rhel} >= 6 -BuildRequires: qtbrowserplugin-static -%endif - %if "%{?_vendor}" == "redhat" %if 0%{?fedora} || 0%{?el7} BuildRequires: man2html-core @@ -85,6 +81,7 @@ BuildRoot: %(mktemp -ud %{_tmppath}/%{name}-%{version}-%{release}-XXXXXX) BuildRoot: %{_tmppath}/%{name}-%{version}-build %endif + %description X2Go is a server-based computing environment with - session resuming @@ -99,57 +96,10 @@ X2Go Client is a graphical client (Qt4) for the X2Go system. You can use it to connect to running sessions and start new sessions. -%package -n x2goplugin -Summary: X2Go Client (Qt4) as browser plugin -Group: Applications/Communications -Requires: mozilla-filesystem -Requires: nxproxy -%if 0%{?suse_version} -Requires: openssh -%else -Requires: openssh-clients, openssh-server -%endif - - -%description -n x2goplugin -X2Go is a server-based computing environment with - - session resuming - - low bandwidth support - - session brokerage support - - client-side mass storage mounting support - - client-side printing support - - audio support - - authentication by smartcard and USB stick - -X2Go Client is a graphical client (qt4) for the X2Go system. -You can use it to connect to running sessions and start new sessions. - -This package provides X2Go Client as QtBrowser-based Mozilla plugin. - - -%package -n x2goplugin-provider -Summary: Provide X2Go Plugin via Apache webserver -Group: Applications/Communications -Requires: httpd - -%description -n x2goplugin-provider -X2Go is a server-based computing environment with - - session resuming - - low bandwidth support - - session brokerage support - - client-side mass storage mounting support - - client-side printing support - - audio support - - authentication by smartcard and USB stick - -This package provides an example configuration for providing -the X2Go Plugin via an Apache webserver. - %prep %setup -q # Fix up install issues sed -i -e 's/-o root -g root//' Makefile -sed -i -e '/^MOZPLUGDIR=/s/lib/%{_lib}/' Makefile test -f ChangeLog && cp ChangeLog res/txt/changelog || test -f debian/changelog && cp debian/changelog res/txt/changelog || true test -f ChangeLog.gitlog && cp ChangeLog.gitlog res/txt/git-info || true %if 0%{?el5} @@ -160,13 +110,6 @@ sed -i -e '/^LRELEASE_BINARY=/s@lrelease-qt4@%{_libdir}/qt4/bin/lrelease@' Makef sed -i -e '/^QMAKE_BINARY=/s@qmake-qt4@%{_bindir}/qmake@' Makefile sed -i -e '/^LRELEASE_BINARY=/s@lrelease-qt4@%{_bindir}/lrelease@' Makefile %endif -%if 0%{?fedora} >= 19 || 0%{?rhel} >= 6 -# Use system qtbrowserplugin -sed -i -e '/CFGPLUGIN/aTEMPLATE=lib' x2goclient.pro -sed -i -e '/^LIBS /s/$/ -ldl/' x2goclient.pro -sed -i -e 's/include.*qtbrowserplugin.pri)/LIBS += -lqtbrowserplugin/' x2goclient.pro -rm -r x2gobrowserplugin* || : -%endif %build @@ -179,21 +122,15 @@ make install DESTDIR=%{buildroot} PREFIX=%{_prefix} desktop-file-validate %{buildroot}%{_datadir}/applications/%{name}.desktop %if 0%{?suse_version} -mkdir -p %{buildroot}%{_sysconfdir}/apache2/conf.d -ln -s ../../x2go/x2goplugin-apache.conf %{buildroot}%{_sysconfdir}/apache2/conf.d/x2goplugin-provider.conf -%else -mkdir -p %{buildroot}%{_sysconfdir}/httpd/conf.d -ln -s ../../x2go/x2goplugin-apache.conf %{buildroot}%{_sysconfdir}/httpd/conf.d/x2goplugin-provider.conf -%endif - -%if 0%{?suse_version} %suse_update_desktop_file -r x2goclient Utility WebUtility %fdupes %buildroot %endif + %post /bin/touch --no-create %{_datadir}/icons/hicolor &>/dev/null || : + %postun if [ $1 -eq 0 ] ; then /bin/touch --no-create %{_datadir}/icons/hicolor &>/dev/null @@ -226,29 +163,4 @@ fi %{_mandir}/man1/%{name}.1.gz -%files -n x2goplugin -%defattr(-,root,root) -%dir %{_libdir}/mozilla -%dir %{_libdir}/mozilla/plugins -%{_libdir}/mozilla/plugins/libx2goplugin.so - -%files -n x2goplugin-provider -%defattr(-,root,root) -# Link -%if 0%{?suse_version} -%dir %{_sysconfdir}/apache2/ -%dir %{_sysconfdir}/apache2/conf.d/ -%{_sysconfdir}/apache2/conf.d/x2goplugin-provider.conf -%else -%dir %{_sysconfdir}/httpd/ -%dir %{_sysconfdir}/httpd/conf.d/ -%{_sysconfdir}/httpd/conf.d/x2goplugin-provider.conf -%endif -%dir %{_sysconfdir}/x2go -%dir %{_sysconfdir}/x2go/plugin-provider -%config(noreplace) %{_sysconfdir}/x2go/plugin-provider/x2goplugin.html -%config(noreplace) %{_sysconfdir}/x2go/x2goplugin-apache.conf -%{_datadir}/x2go/ - - %changelog -- Alioth's /home/x2go-admin/maintenancescripts/git/hooks/post-receive-email on /srv/git/code.x2go.org/x2goclient.git
This is an automated email from the git hooks/post-receive script. x2go pushed a commit to branch master in repository x2goclient. commit c92b679443668ef8b913d3113eb786d77a603b0d Author: Mihai Moldovan <ionic@ionic.de> Date: Wed Mar 14 00:41:57 2018 +0100 src/sshmasterconnection.cpp: stop libssh/OpenSSL from querying for a passphrase if started with a controlling terminal. --- debian/changelog | 2 ++ src/sshmasterconnection.cpp | 13 ++++++++++++- 2 files changed, 14 insertions(+), 1 deletion(-) diff --git a/debian/changelog b/debian/changelog index 9ce7036..2e0f54c 100644 --- a/debian/changelog +++ b/debian/changelog @@ -28,6 +28,8 @@ x2goclient (4.1.2.0-0x2go1) UNRELEASED; urgency=medium - res/qresources.qrc: add new lxqt files. - src/{onmainwindow.cpp,session{button,widget}.{cpp,h}}: add support for LXQt. Fixes: #1263. + - src/sshmasterconnection.cpp: stop libssh/OpenSSL from querying for a + passphrase if started with a controlling terminal. -- X2Go Release Manager <git-admin@x2go.org> Thu, 15 Feb 2018 22:01:32 +0100 diff --git a/src/sshmasterconnection.cpp b/src/sshmasterconnection.cpp index 0772f3f..7c2f91b 100644 --- a/src/sshmasterconnection.cpp +++ b/src/sshmasterconnection.cpp @@ -1407,7 +1407,18 @@ bool SshMasterConnection::userAuthWithKey() #if LIBSSH_VERSION_INT >= SSH_VERSION_INT (0, 6, 0) ssh_key priv_key = { 0 }; - int rc = ssh_pki_import_privkey_file (tmp_ba.data (), NULL, NULL, NULL, &priv_key); + /* + * Passing an empty string as a passphrase parameter is a workaround for inconsistent + * behavior in libssh: + * - compiled with OpenSSL, libssh lets OpenSSL query the passphrase if the + * application has a controlling terminal connected + * - compiled with libgcrypt, this never happens + * + * We do not want to break user experience by having libssh/OpenSSL query for the + * passphrase on a terminal (and the client not reacting to any input while this + * happens), so work around this inconsistency by providing an empty passphrase. + */ + int rc = ssh_pki_import_privkey_file (tmp_ba.data (), "", NULL, NULL, &priv_key); if (SSH_EOF == rc) { x2goDebug << "Failed to get private key from " << keyName << "; file does not exist."; -- Alioth's /home/x2go-admin/maintenancescripts/git/hooks/post-receive-email on /srv/git/code.x2go.org/x2goclient.git
This is an automated email from the git hooks/post-receive script. x2go pushed a commit to branch master in repository x2goclient. commit 4f70ddf41866e6d757a63d9732745dba50228463 Author: Mihai Moldovan <ionic@ionic.de> Date: Wed Mar 14 02:13:20 2018 +0100 debian/rules: remove plugin references. --- debian/changelog | 2 ++ debian/rules | 6 +----- 2 files changed, 3 insertions(+), 5 deletions(-) diff --git a/debian/changelog b/debian/changelog index 9f92458..6ecdfe1 100644 --- a/debian/changelog +++ b/debian/changelog @@ -35,6 +35,8 @@ x2goclient (4.1.2.0-0x2go1) UNRELEASED; urgency=medium and translation files for now. * x2goclient.spec: - Remove plugin references. + * debian/rules: + - Remove plugin references. -- X2Go Release Manager <git-admin@x2go.org> Thu, 15 Feb 2018 22:01:32 +0100 diff --git a/debian/rules b/debian/rules index 288b6a8..f2e1197 100755 --- a/debian/rules +++ b/debian/rules @@ -6,7 +6,7 @@ export CXXFLAGS:=$(shell dpkg-buildflags --get CXXFLAGS) export LDFLAGS:=$(shell dpkg-buildflags --get LDFLAGS) %: - dh $@ --parallel --with apache2 || dh $@ --parallel + dh $@ --parallel override_dh_auto_configure: cp debian/changelog res/txt/changelog @@ -21,7 +21,3 @@ override_dh_auto_clean: override_dh_strip: dh_strip -p x2goclient --dbg-package=x2goclient-dbg - dh_strip -p x2goplugin --dbg-package=x2goplugin-dbg - -override_dh_apache2: - dh_apache2 --noscripts -- Alioth's /home/x2go-admin/maintenancescripts/git/hooks/post-receive-email on /srv/git/code.x2go.org/x2goclient.git
This is an automated email from the git hooks/post-receive script. x2go pushed a commit to branch master in repository x2goclient. commit 0fa33569a7ba4ea2a4f18bfe8a266f7c8d2f0c80 Author: Mihai Moldovan <ionic@ionic.de> Date: Wed Mar 14 01:17:52 2018 +0100 misc: change http:// to https:// where appropriate, but in actual code and translation files for now. --- COPYRIGHT.x2go-logos | 2 +- INSTALL | 6 +++--- LICENSE | 6 +++--- README.i18n | 2 +- debian/changelog | 2 ++ debian/control | 4 ++-- debian/copyright | 8 ++++---- man/man1/x2goclient.1 | 2 +- nsis/x2goclient.nsi | 4 ++-- pkg-dmg | 2 +- portable/manifest.u3i | 2 +- src/InteractionDialog.cpp | 2 +- src/InteractionDialog.h | 2 +- src/LDAPSession.cpp | 2 +- src/LDAPSession.h | 2 +- src/SVGFrame.cpp | 2 +- src/SVGFrame.h | 2 +- src/appdialog.cpp | 2 +- src/appdialog.h | 2 +- src/brokerpassdlg.cpp | 2 +- src/brokerpassdlg.h | 2 +- src/clicklineedit.cpp | 2 +- src/clicklineedit.h | 2 +- src/configdialog.cpp | 2 +- src/configdialog.h | 2 +- src/configwidget.cpp | 2 +- src/configwidget.h | 2 +- src/connectionwidget.cpp | 2 +- src/connectionwidget.h | 2 +- src/contest.cpp | 2 +- src/contest.h | 2 +- src/cupsprint.cpp | 2 +- src/cupsprint.h | 2 +- src/cupsprintersettingsdialog.cpp | 2 +- src/cupsprintersettingsdialog.h | 2 +- src/cupsprintwidget.cpp | 2 +- src/cupsprintwidget.h | 2 +- src/editconnectiondialog.cpp | 2 +- src/editconnectiondialog.h | 2 +- src/exportdialog.cpp | 2 +- src/exportdialog.h | 2 +- src/folderbutton.cpp | 2 +- src/folderbutton.h | 2 +- src/folderexplorer.cpp | 2 +- src/folderexplorer.h | 2 +- src/helpdialog.cpp | 2 +- src/helpdialog.h | 2 +- src/httpbrokerclient.cpp | 2 +- src/httpbrokerclient.h | 2 +- src/imgframe.cpp | 2 +- src/imgframe.h | 2 +- src/mediawidget.cpp | 2 +- src/mediawidget.h | 2 +- src/non_modal_messagebox.cpp | 2 +- src/non_modal_messagebox.h | 2 +- src/ongetpass.cpp | 2 +- src/ongetpass.h | 2 +- src/onmainwindow.cpp | 2 +- src/onmainwindow.h | 2 +- src/onmainwindow_privat.h | 2 +- src/printdialog.cpp | 2 +- src/printdialog.h | 2 +- src/printercmddialog.cpp | 2 +- src/printercmddialog.h | 2 +- src/printprocess.cpp | 2 +- src/printprocess.h | 2 +- src/printwidget.cpp | 2 +- src/printwidget.h | 2 +- src/sessionbutton.cpp | 2 +- src/sessionbutton.h | 2 +- src/sessionexplorer.cpp | 2 +- src/sessionexplorer.h | 2 +- src/sessionmanagedialog.cpp | 2 +- src/sessionmanagedialog.h | 2 +- src/sessionwidget.cpp | 2 +- src/sessionwidget.h | 2 +- src/settingswidget.cpp | 2 +- src/settingswidget.h | 2 +- src/sharewidget.cpp | 2 +- src/sharewidget.h | 2 +- src/sshmasterconnection.cpp | 2 +- src/sshmasterconnection.h | 2 +- src/sshprocess.cpp | 2 +- src/sshprocess.h | 2 +- src/userbutton.cpp | 2 +- src/userbutton.h | 2 +- src/version.h | 2 +- src/wapi.cpp | 2 +- src/wapi.h | 2 +- src/x2goclient.cpp | 2 +- src/x2goclientconfig.h | 2 +- src/x2gologdebug.cpp | 2 +- src/x2gologdebug.h | 2 +- src/x2gosettings.cpp | 2 +- src/x2gosettings.h | 2 +- src/x2goutils.cpp | 2 +- src/x2goutils.h | 2 +- src/xsettingswidget.cpp | 2 +- src/xsettingswidget.h | 2 +- x2goclient.spec | 4 ++-- x2gohelper/x2gohelper.cpp | 2 +- 101 files changed, 112 insertions(+), 110 deletions(-) diff --git a/COPYRIGHT.x2go-logos b/COPYRIGHT.x2go-logos index 6e3c569..e47ba13 100644 --- a/COPYRIGHT.x2go-logos +++ b/COPYRIGHT.x2go-logos @@ -1,4 +1,4 @@ -Format: http://www.debian.org/doc/packaging-manuals/copyright-format/1.0/ +Format: https://www.debian.org/doc/packaging-manuals/copyright-format/1.0/ Upstream-Name: X2Go-artwork [~X] Upstream-Contact: Heinz-M. Graesing <heinz-m.graesing@obviously-nice.de> diff --git a/INSTALL b/INSTALL index 89ce396..cd9412a 100644 --- a/INSTALL +++ b/INSTALL @@ -4,13 +4,13 @@ Requirements Before use this program you need to install: Qt4: -http://download.qt.io/archive/qt/ +https://download.qt.io/archive/qt/ nxcomp + nxproxy: -http://code.x2go.org/releases/source/nx-libs/ +https://code.x2go.org/releases/source/nx-libs/ You may want also install the PulseAudio sound server and client to enable sound support -http://www.freedesktop.org/wiki/Software/PulseAudio/Download/ +https://www.freedesktop.org/wiki/Software/PulseAudio/Download/ Building diff --git a/LICENSE b/LICENSE index 612f591..e442de5 100644 --- a/LICENSE +++ b/LICENSE @@ -1,5 +1,5 @@ -Copyright (C) 2005-2017 Obviously Nice -- http://www.obviously-nice.de -Copyright (C) 2007-2017 X2Go Project -- http://wiki.x2go.org +Copyright (C) 2005-2017 Obviously Nice -- https://www.obviously-nice.de +Copyright (C) 2007-2017 X2Go Project -- https://wiki.x2go.org This program is free software; you can redistribute it and/or modify it under the terms of the GNU General Public License as published by @@ -12,7 +12,7 @@ MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for more details. You should have received a copy of the GNU General Public License -along with this program. If not, see <http://www.gnu.org/licenses/>. +along with this program. If not, see <https://www.gnu.org/licenses/>. Copyright (C) 2005-2017 Oleksandr Shneyder <o.shneyder@phoca-gmbh.de> Copyright (C) 2005-2017 Heinz-Markus Graesing <heinz-m.graesing@obviously-nice.de> diff --git a/README.i18n b/README.i18n index d2a9386..8826286 100644 --- a/README.i18n +++ b/README.i18n @@ -16,7 +16,7 @@ THANKS!!! for the time you give to the X2Go project. And, if you are new to the team and language files for the language you want to feel responsible for do not yet exist, please subscribe to this mailing list first: - http://lists.x2go.org/listinfo/x2go-i18n + https://lists.x2go.org/listinfo/x2go-i18n Once you are subscribed, send an email to diff --git a/debian/changelog b/debian/changelog index a15229a..9f92458 100644 --- a/debian/changelog +++ b/debian/changelog @@ -31,6 +31,8 @@ x2goclient (4.1.2.0-0x2go1) UNRELEASED; urgency=medium - src/sshmasterconnection.cpp: stop libssh/OpenSSL from querying for a passphrase if started with a controlling terminal. - x2goclient.pro: remove plugin references. + - misc: change http:// to https:// where appropriate, but in actual code + and translation files for now. * x2goclient.spec: - Remove plugin references. diff --git a/debian/control b/debian/control index bd59a35..86d3e78 100644 --- a/debian/control +++ b/debian/control @@ -17,9 +17,9 @@ Build-Depends: man2html-base | man2html, apache2-dev | apache2-threaded-dev, Standards-Version: 3.9.5 -Homepage: http://code.x2go.org/releases/source/x2goclient +Homepage: https://code.x2go.org/releases/source/x2goclient Vcs-Git: git://code.x2go.org/x2goclient.git -Vcs-Browser: http://code.x2go.org/gitweb?p=x2goclient.git;a=summary +Vcs-Browser: https://code.x2go.org/gitweb?p=x2goclient.git;a=summary Package: x2goclient Architecture: any diff --git a/debian/copyright b/debian/copyright index d1edcf7..a48bb40 100644 --- a/debian/copyright +++ b/debian/copyright @@ -1,12 +1,12 @@ -Format: http://www.debian.org/doc/packaging-manuals/copyright-format/1.0/ +Format: https://www.debian.org/doc/packaging-manuals/copyright-format/1.0/ Upstream-Name: x2goclient Upstream-Contact: Oleksandr Shneyder <oleksandr.shneyder@obviously-nice.de> -Source: http://wiki.x2go.org +Source: https://wiki.x2go.org Files: * Copyright: 2005-2017, Oleksandr Shneyder <oleksandr.shneyder@obviously-nice.de> 2005-2017, Heinz-Markus Graesing <heinz-m.graesing@obviously-nice.de> - 2005-2017, obviously nice - http://www.obviously-nice.de + 2005-2017, obviously nice - https://www.obviously-nice.de License: GPL-2+ This program is free software; you can redistribute it and/or modify it under the terms of the GNU General Public @@ -92,7 +92,7 @@ License: GPL-3 GNU General Public License for more details. . You should have received a copy of the GNU General Public License - along with this program. If not, see <http://www.gnu.org/licenses/>. + along with this program. If not, see <https://www.gnu.org/licenses/>. . On Debian systems, the full text of the GNU General Public License version 3 can be found in the file diff --git a/man/man1/x2goclient.1 b/man/man1/x2goclient.1 index 91c7595..5c566e7 100644 --- a/man/man1/x2goclient.1 +++ b/man/man1/x2goclient.1 @@ -298,4 +298,4 @@ Allow client side printing in LDAP mode. .PP .SH AUTHOR This manual has been written by Mike Gabriel <mike.gabriel@das-netzwerkteam.de> for the X2Go project -(http://www.x2go.org). +(https://www.x2go.org). diff --git a/nsis/x2goclient.nsi b/nsis/x2goclient.nsi index d1fdcd9..5f9e4f6 100644 --- a/nsis/x2goclient.nsi +++ b/nsis/x2goclient.nsi @@ -61,7 +61,7 @@ SectionEnd !define UNINSTALL_DISPLAYNAME "X2Go Client for Windows" !define UNINSTALL_PUBLISHER "X2Go Project" !define UNINSTALL_DISPLAYVERSION ${VERSION} - !define UNINSTALL_URL "http://www.x2go.org" + !define UNINSTALL_URL "https://www.x2go.org" ;-------------------------------- ;Pages @@ -148,7 +148,7 @@ Section "X2Go Client (required)" base !insertmacro MUI_STARTMENU_WRITE_END ;Add uninstall information to Add/Remove Programs - ;http://nsis.sourceforge.net/Add_uninstall_information_to_Add/Remove_Programs + ;https://nsis.sourceforge.net/Add_uninstall_information_to_Add/Remove_Program... WriteRegStr HKLM ${UNINSTALL_REGKEY} "InstallLocation" "$INSTDIR" WriteRegStr HKLM ${UNINSTALL_REGKEY} "UninstallString" "$\"$INSTDIR\Uninstall.exe$\"" WriteRegStr HKLM ${UNINSTALL_REGKEY} "DisplayIcon" "$INSTDIR\x2goclient.exe" diff --git a/pkg-dmg b/pkg-dmg index 82b9010..cb4e402 100755 --- a/pkg-dmg +++ b/pkg-dmg @@ -5,7 +5,7 @@ # The contents of this file are subject to the Mozilla Public License Version # 1.1 (the "License"); you may not use this file except in compliance with # the License. You may obtain a copy of the License at -# http://www.mozilla.org/MPL/ +# https://www.mozilla.org/MPL/ # # Software distributed under the License is distributed on an "AS IS" basis, # WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License diff --git a/portable/manifest.u3i b/portable/manifest.u3i index 2bd0555..4461db4 100644 --- a/portable/manifest.u3i +++ b/portable/manifest.u3i @@ -3,7 +3,7 @@ <application uuid="F9C45380-833B-424b-B70E-5023BCD51E79" version="3.01.12"> <icon>x2goclient.ico</icon> <name>Portable X2Go Client for Windows</name> -<vendor url="http://x2go.org">x2go</vendor> +<vendor url="https://x2go.org">x2go</vendor> <description>Portable X2Go Client for Windows</description> <options> diff --git a/src/InteractionDialog.cpp b/src/InteractionDialog.cpp index f51ae80..6ab5d45 100644 --- a/src/InteractionDialog.cpp +++ b/src/InteractionDialog.cpp @@ -12,7 +12,7 @@ * GNU General Public License for more details. * * * * You should have received a copy of the GNU General Public License * -* along with this program. If not, see <http://www.gnu.org/licenses/>. * +* along with this program. If not, see <https://www.gnu.org/licenses/>. * ***************************************************************************/ #include "InteractionDialog.h" diff --git a/src/InteractionDialog.h b/src/InteractionDialog.h index 8c9d531..c0238eb 100644 --- a/src/InteractionDialog.h +++ b/src/InteractionDialog.h @@ -12,7 +12,7 @@ * GNU General Public License for more details. * * * * You should have received a copy of the GNU General Public License * -* along with this program. If not, see <http://www.gnu.org/licenses/>. * +* along with this program. If not, see <https://www.gnu.org/licenses/>. * ***************************************************************************/ #ifndef INTERACTIONDIALOG_H diff --git a/src/LDAPSession.cpp b/src/LDAPSession.cpp index 87c6bc0..df25a5c 100644 --- a/src/LDAPSession.cpp +++ b/src/LDAPSession.cpp @@ -12,7 +12,7 @@ * GNU General Public License for more details. * * * * You should have received a copy of the GNU General Public License * -* along with this program. If not, see <http://www.gnu.org/licenses/>. * +* along with this program. If not, see <https://www.gnu.org/licenses/>. * ***************************************************************************/ #include "LDAPSession.h" diff --git a/src/LDAPSession.h b/src/LDAPSession.h index b5d4a5c..313ff09 100644 --- a/src/LDAPSession.h +++ b/src/LDAPSession.h @@ -12,7 +12,7 @@ * GNU General Public License for more details. * * * * You should have received a copy of the GNU General Public License * -* along with this program. If not, see <http://www.gnu.org/licenses/>. * +* along with this program. If not, see <https://www.gnu.org/licenses/>. * ***************************************************************************/ #ifndef LDAPSESSION_H diff --git a/src/SVGFrame.cpp b/src/SVGFrame.cpp index 4133f81..579d29a 100644 --- a/src/SVGFrame.cpp +++ b/src/SVGFrame.cpp @@ -12,7 +12,7 @@ * GNU General Public License for more details. * * * * You should have received a copy of the GNU General Public License * -* along with this program. If not, see <http://www.gnu.org/licenses/>. * +* along with this program. If not, see <https://www.gnu.org/licenses/>. * ***************************************************************************/ #include "SVGFrame.h" diff --git a/src/SVGFrame.h b/src/SVGFrame.h index b9024f6..863af3a 100644 --- a/src/SVGFrame.h +++ b/src/SVGFrame.h @@ -12,7 +12,7 @@ * GNU General Public License for more details. * * * * You should have received a copy of the GNU General Public License * -* along with this program. If not, see <http://www.gnu.org/licenses/>. * +* along with this program. If not, see <https://www.gnu.org/licenses/>. * ***************************************************************************/ #ifndef SVGFRAME_H diff --git a/src/appdialog.cpp b/src/appdialog.cpp index 2276ce8..ff506ce 100644 --- a/src/appdialog.cpp +++ b/src/appdialog.cpp @@ -12,7 +12,7 @@ * GNU General Public License for more details. * * * * You should have received a copy of the GNU General Public License * -* along with this program. If not, see <http://www.gnu.org/licenses/>. * +* along with this program. If not, see <https://www.gnu.org/licenses/>. * ***************************************************************************/ #include "appdialog.h" #include "onmainwindow.h" diff --git a/src/appdialog.h b/src/appdialog.h index 593c32f..2cf7518 100644 --- a/src/appdialog.h +++ b/src/appdialog.h @@ -12,7 +12,7 @@ * GNU General Public License for more details. * * * * You should have received a copy of the GNU General Public License * -* along with this program. If not, see <http://www.gnu.org/licenses/>. * +* along with this program. If not, see <https://www.gnu.org/licenses/>. * ***************************************************************************/ #ifndef APPDIALOG_H #define APPDIALOG_H diff --git a/src/brokerpassdlg.cpp b/src/brokerpassdlg.cpp index fd1d575..30101f0 100644 --- a/src/brokerpassdlg.cpp +++ b/src/brokerpassdlg.cpp @@ -12,7 +12,7 @@ * GNU General Public License for more details. * * * * You should have received a copy of the GNU General Public License * -* along with this program. If not, see <http://www.gnu.org/licenses/>. * +* along with this program. If not, see <https://www.gnu.org/licenses/>. * ***************************************************************************/ #include "brokerpassdlg.h" diff --git a/src/brokerpassdlg.h b/src/brokerpassdlg.h index 1ecc177..1bf4dca 100644 --- a/src/brokerpassdlg.h +++ b/src/brokerpassdlg.h @@ -12,7 +12,7 @@ * GNU General Public License for more details. * * * * You should have received a copy of the GNU General Public License * -* along with this program. If not, see <http://www.gnu.org/licenses/>. * +* along with this program. If not, see <https://www.gnu.org/licenses/>. * ***************************************************************************/ #ifndef BROKERPASSDLG_H diff --git a/src/clicklineedit.cpp b/src/clicklineedit.cpp index 2da487e..8833ad6 100644 --- a/src/clicklineedit.cpp +++ b/src/clicklineedit.cpp @@ -12,7 +12,7 @@ * GNU General Public License for more details. * * * * You should have received a copy of the GNU General Public License * -* along with this program. If not, see <http://www.gnu.org/licenses/>. * +* along with this program. If not, see <https://www.gnu.org/licenses/>. * ***************************************************************************/ #include "clicklineedit.h" diff --git a/src/clicklineedit.h b/src/clicklineedit.h index 194b10e..0834ecd 100644 --- a/src/clicklineedit.h +++ b/src/clicklineedit.h @@ -12,7 +12,7 @@ * GNU General Public License for more details. * * * * You should have received a copy of the GNU General Public License * -* along with this program. If not, see <http://www.gnu.org/licenses/>. * +* along with this program. If not, see <https://www.gnu.org/licenses/>. * ***************************************************************************/ #ifndef CLICKLINEEDIT_H diff --git a/src/configdialog.cpp b/src/configdialog.cpp index 481948d..565333a 100644 --- a/src/configdialog.cpp +++ b/src/configdialog.cpp @@ -12,7 +12,7 @@ * GNU General Public License for more details. * * * * You should have received a copy of the GNU General Public License * -* along with this program. If not, see <http://www.gnu.org/licenses/>. * +* along with this program. If not, see <https://www.gnu.org/licenses/>. * ***************************************************************************/ #include <QLineEdit> diff --git a/src/configdialog.h b/src/configdialog.h index d82d0d0..6c15529 100644 --- a/src/configdialog.h +++ b/src/configdialog.h @@ -12,7 +12,7 @@ * GNU General Public License for more details. * * * * You should have received a copy of the GNU General Public License * -* along with this program. If not, see <http://www.gnu.org/licenses/>. * +* along with this program. If not, see <https://www.gnu.org/licenses/>. * ***************************************************************************/ #ifndef CONFIGDIALOG_H diff --git a/src/configwidget.cpp b/src/configwidget.cpp index 52a7fe5..85aa32e 100644 --- a/src/configwidget.cpp +++ b/src/configwidget.cpp @@ -12,7 +12,7 @@ * GNU General Public License for more details. * * * * You should have received a copy of the GNU General Public License * -* along with this program. If not, see <http://www.gnu.org/licenses/>. * +* along with this program. If not, see <https://www.gnu.org/licenses/>. * ***************************************************************************/ #include "configwidget.h" diff --git a/src/configwidget.h b/src/configwidget.h index cd14265..20d7371 100644 --- a/src/configwidget.h +++ b/src/configwidget.h @@ -12,7 +12,7 @@ * GNU General Public License for more details. * * * * You should have received a copy of the GNU General Public License * -* along with this program. If not, see <http://www.gnu.org/licenses/>. * +* along with this program. If not, see <https://www.gnu.org/licenses/>. * ***************************************************************************/ #ifndef CONFIGWIDGET_H diff --git a/src/connectionwidget.cpp b/src/connectionwidget.cpp index 9698ae1..ae295dd 100644 --- a/src/connectionwidget.cpp +++ b/src/connectionwidget.cpp @@ -12,7 +12,7 @@ * GNU General Public License for more details. * * * * You should have received a copy of the GNU General Public License * -* along with this program. If not, see <http://www.gnu.org/licenses/>. * +* along with this program. If not, see <https://www.gnu.org/licenses/>. * ***************************************************************************/ #include "connectionwidget.h" diff --git a/src/connectionwidget.h b/src/connectionwidget.h index c553170..128a8c9 100644 --- a/src/connectionwidget.h +++ b/src/connectionwidget.h @@ -12,7 +12,7 @@ * GNU General Public License for more details. * * * * You should have received a copy of the GNU General Public License * -* along with this program. If not, see <http://www.gnu.org/licenses/>. * +* along with this program. If not, see <https://www.gnu.org/licenses/>. * ***************************************************************************/ #ifndef CONNECTIONWIDGET_H diff --git a/src/contest.cpp b/src/contest.cpp index 44df739..1f186c8 100644 --- a/src/contest.cpp +++ b/src/contest.cpp @@ -12,7 +12,7 @@ * GNU General Public License for more details. * * * * You should have received a copy of the GNU General Public License * -* along with this program. If not, see <http://www.gnu.org/licenses/>. * +* along with this program. If not, see <https://www.gnu.org/licenses/>. * ***************************************************************************/ #include "contest.h" diff --git a/src/contest.h b/src/contest.h index 8557136..5f538eb 100644 --- a/src/contest.h +++ b/src/contest.h @@ -12,7 +12,7 @@ * GNU General Public License for more details. * * * * You should have received a copy of the GNU General Public License * -* along with this program. If not, see <http://www.gnu.org/licenses/>. * +* along with this program. If not, see <https://www.gnu.org/licenses/>. * ***************************************************************************/ #ifndef CONTEST_H diff --git a/src/cupsprint.cpp b/src/cupsprint.cpp index 22c9420..ff53fcb 100644 --- a/src/cupsprint.cpp +++ b/src/cupsprint.cpp @@ -12,7 +12,7 @@ * GNU General Public License for more details. * * * * You should have received a copy of the GNU General Public License * -* along with this program. If not, see <http://www.gnu.org/licenses/>. * +* along with this program. If not, see <https://www.gnu.org/licenses/>. * ***************************************************************************/ #include "cupsprint.h" diff --git a/src/cupsprint.h b/src/cupsprint.h index 9c64d48..cea1d23 100644 --- a/src/cupsprint.h +++ b/src/cupsprint.h @@ -12,7 +12,7 @@ * GNU General Public License for more details. * * * * You should have received a copy of the GNU General Public License * -* along with this program. If not, see <http://www.gnu.org/licenses/>. * +* along with this program. If not, see <https://www.gnu.org/licenses/>. * ***************************************************************************/ #ifndef CUPSPRINT_H diff --git a/src/cupsprintersettingsdialog.cpp b/src/cupsprintersettingsdialog.cpp index 6fd17c6..e5f92a4 100644 --- a/src/cupsprintersettingsdialog.cpp +++ b/src/cupsprintersettingsdialog.cpp @@ -12,7 +12,7 @@ * GNU General Public License for more details. * * * * You should have received a copy of the GNU General Public License * -* along with this program. If not, see <http://www.gnu.org/licenses/>. * +* along with this program. If not, see <https://www.gnu.org/licenses/>. * ***************************************************************************/ #include "cupsprintersettingsdialog.h" diff --git a/src/cupsprintersettingsdialog.h b/src/cupsprintersettingsdialog.h index bfbf9c5..bfa751f 100644 --- a/src/cupsprintersettingsdialog.h +++ b/src/cupsprintersettingsdialog.h @@ -12,7 +12,7 @@ * GNU General Public License for more details. * * * * You should have received a copy of the GNU General Public License * -* along with this program. If not, see <http://www.gnu.org/licenses/>. * +* along with this program. If not, see <https://www.gnu.org/licenses/>. * ***************************************************************************/ #ifndef CUPSPRINTERSETTINGSDIALOG_H diff --git a/src/cupsprintwidget.cpp b/src/cupsprintwidget.cpp index f1b7d10..c4f008f 100644 --- a/src/cupsprintwidget.cpp +++ b/src/cupsprintwidget.cpp @@ -12,7 +12,7 @@ * GNU General Public License for more details. * * * * You should have received a copy of the GNU General Public License * -* along with this program. If not, see <http://www.gnu.org/licenses/>. * +* along with this program. If not, see <https://www.gnu.org/licenses/>. * ***************************************************************************/ #include "cupsprint.h" diff --git a/src/cupsprintwidget.h b/src/cupsprintwidget.h index 54142e0..82a9d39 100644 --- a/src/cupsprintwidget.h +++ b/src/cupsprintwidget.h @@ -12,7 +12,7 @@ * GNU General Public License for more details. * * * * You should have received a copy of the GNU General Public License * -* along with this program. If not, see <http://www.gnu.org/licenses/>. * +* along with this program. If not, see <https://www.gnu.org/licenses/>. * ***************************************************************************/ #ifndef CUPSPRINTWIDGET_H diff --git a/src/editconnectiondialog.cpp b/src/editconnectiondialog.cpp index df3fe26..eeb67ba 100644 --- a/src/editconnectiondialog.cpp +++ b/src/editconnectiondialog.cpp @@ -12,7 +12,7 @@ * GNU General Public License for more details. * * * * You should have received a copy of the GNU General Public License * -* along with this program. If not, see <http://www.gnu.org/licenses/>. * +* along with this program. If not, see <https://www.gnu.org/licenses/>. * ***************************************************************************/ #include "editconnectiondialog.h" diff --git a/src/editconnectiondialog.h b/src/editconnectiondialog.h index 05a3a9e..de41534 100644 --- a/src/editconnectiondialog.h +++ b/src/editconnectiondialog.h @@ -12,7 +12,7 @@ * GNU General Public License for more details. * * * * You should have received a copy of the GNU General Public License * -* along with this program. If not, see <http://www.gnu.org/licenses/>. * +* along with this program. If not, see <https://www.gnu.org/licenses/>. * ***************************************************************************/ #ifndef EDITCONNECTIONDIALOG_H diff --git a/src/exportdialog.cpp b/src/exportdialog.cpp index 2b1eeef..8931cc4 100644 --- a/src/exportdialog.cpp +++ b/src/exportdialog.cpp @@ -12,7 +12,7 @@ * GNU General Public License for more details. * * * * You should have received a copy of the GNU General Public License * -* along with this program. If not, see <http://www.gnu.org/licenses/>. * +* along with this program. If not, see <https://www.gnu.org/licenses/>. * ***************************************************************************/ #include "x2goclientconfig.h" diff --git a/src/exportdialog.h b/src/exportdialog.h index 94ce4da..92eef10 100644 --- a/src/exportdialog.h +++ b/src/exportdialog.h @@ -12,7 +12,7 @@ * GNU General Public License for more details. * * * * You should have received a copy of the GNU General Public License * -* along with this program. If not, see <http://www.gnu.org/licenses/>. * +* along with this program. If not, see <https://www.gnu.org/licenses/>. * ***************************************************************************/ #ifndef EXPORTDIALOG_H diff --git a/src/folderbutton.cpp b/src/folderbutton.cpp index 7610b34..7ec9012 100644 --- a/src/folderbutton.cpp +++ b/src/folderbutton.cpp @@ -12,7 +12,7 @@ * GNU General Public License for more details. * * * * You should have received a copy of the GNU General Public License * -* along with this program. If not, see <http://www.gnu.org/licenses/>. * +* along with this program. If not, see <https://www.gnu.org/licenses/>. * ***************************************************************************/ #include "folderbutton.h" diff --git a/src/folderbutton.h b/src/folderbutton.h index 184f708..58cfaae 100644 --- a/src/folderbutton.h +++ b/src/folderbutton.h @@ -12,7 +12,7 @@ * GNU General Public License for more details. * * * * You should have received a copy of the GNU General Public License * -* along with this program. If not, see <http://www.gnu.org/licenses/>. * +* along with this program. If not, see <https://www.gnu.org/licenses/>. * ***************************************************************************/ #ifndef FOLDERBUTTON_H diff --git a/src/folderexplorer.cpp b/src/folderexplorer.cpp index e2b5d51..46e939b 100644 --- a/src/folderexplorer.cpp +++ b/src/folderexplorer.cpp @@ -12,7 +12,7 @@ * GNU General Public License for more details. * * * * You should have received a copy of the GNU General Public License * -* along with this program. If not, see <http://www.gnu.org/licenses/>. * +* along with this program. If not, see <https://www.gnu.org/licenses/>. * ***************************************************************************/ #include "folderexplorer.h" #include "x2gologdebug.h" diff --git a/src/folderexplorer.h b/src/folderexplorer.h index acaf95f..a001a33 100644 --- a/src/folderexplorer.h +++ b/src/folderexplorer.h @@ -12,7 +12,7 @@ * GNU General Public License for more details. * * * * You should have received a copy of the GNU General Public License * -* along with this program. If not, see <http://www.gnu.org/licenses/>. * +* along with this program. If not, see <https://www.gnu.org/licenses/>. * ***************************************************************************/ #ifndef FOLDEREXPLORER_H #define FOLDEREXPLORER_H diff --git a/src/helpdialog.cpp b/src/helpdialog.cpp index bbbe645..923997a 100644 --- a/src/helpdialog.cpp +++ b/src/helpdialog.cpp @@ -13,7 +13,7 @@ * GNU General Public License for more details. * * * * You should have received a copy of the GNU General Public License * -* along with this program. If not, see <http://www.gnu.org/licenses/>. * +* along with this program. If not, see <https://www.gnu.org/licenses/>. * ***************************************************************************/ #include <QtGlobal> diff --git a/src/helpdialog.h b/src/helpdialog.h index 7a7a199..3dd2e6d 100644 --- a/src/helpdialog.h +++ b/src/helpdialog.h @@ -13,7 +13,7 @@ * GNU General Public License for more details. * * * * You should have received a copy of the GNU General Public License * -* along with this program. If not, see <http://www.gnu.org/licenses/>. * +* along with this program. If not, see <https://www.gnu.org/licenses/>. * ***************************************************************************/ #ifndef HELPDIALOG_H diff --git a/src/httpbrokerclient.cpp b/src/httpbrokerclient.cpp index 1416348..f7fbaf1 100644 --- a/src/httpbrokerclient.cpp +++ b/src/httpbrokerclient.cpp @@ -12,7 +12,7 @@ * GNU General Public License for more details. * * * * You should have received a copy of the GNU General Public License * -* along with this program. If not, see <http://www.gnu.org/licenses/>. * +* along with this program. If not, see <https://www.gnu.org/licenses/>. * ***************************************************************************/ #include "httpbrokerclient.h" diff --git a/src/httpbrokerclient.h b/src/httpbrokerclient.h index 3cb0eb0..0a307e1 100644 --- a/src/httpbrokerclient.h +++ b/src/httpbrokerclient.h @@ -12,7 +12,7 @@ * GNU General Public License for more details. * * * * You should have received a copy of the GNU General Public License * -* along with this program. If not, see <http://www.gnu.org/licenses/>. * +* along with this program. If not, see <https://www.gnu.org/licenses/>. * ***************************************************************************/ #ifndef HTTPBROKERCLIENT_H diff --git a/src/imgframe.cpp b/src/imgframe.cpp index 708de17..b506ea6 100644 --- a/src/imgframe.cpp +++ b/src/imgframe.cpp @@ -12,7 +12,7 @@ * GNU General Public License for more details. * * * * You should have received a copy of the GNU General Public License * -* along with this program. If not, see <http://www.gnu.org/licenses/>. * +* along with this program. If not, see <https://www.gnu.org/licenses/>. * ***************************************************************************/ #include "imgframe.h" diff --git a/src/imgframe.h b/src/imgframe.h index f11efd5..ed2d21d 100644 --- a/src/imgframe.h +++ b/src/imgframe.h @@ -12,7 +12,7 @@ * GNU General Public License for more details. * * * * You should have received a copy of the GNU General Public License * -* along with this program. If not, see <http://www.gnu.org/licenses/>. * +* along with this program. If not, see <https://www.gnu.org/licenses/>. * ***************************************************************************/ #ifndef IMGFRAME_H diff --git a/src/mediawidget.cpp b/src/mediawidget.cpp index c4686bd..40fab92 100644 --- a/src/mediawidget.cpp +++ b/src/mediawidget.cpp @@ -12,7 +12,7 @@ * GNU General Public License for more details. * * * * You should have received a copy of the GNU General Public License * -* along with this program. If not, see <http://www.gnu.org/licenses/>. * +* along with this program. If not, see <https://www.gnu.org/licenses/>. * ***************************************************************************/ #include "mediawidget.h" diff --git a/src/mediawidget.h b/src/mediawidget.h index 935c6bd..7564e6e 100644 --- a/src/mediawidget.h +++ b/src/mediawidget.h @@ -12,7 +12,7 @@ * GNU General Public License for more details. * * * * You should have received a copy of the GNU General Public License * -* along with this program. If not, see <http://www.gnu.org/licenses/>. * +* along with this program. If not, see <https://www.gnu.org/licenses/>. * ***************************************************************************/ #ifndef MEDIAWIDGET_H diff --git a/src/non_modal_messagebox.cpp b/src/non_modal_messagebox.cpp index 857b7a8..55c762d 100644 --- a/src/non_modal_messagebox.cpp +++ b/src/non_modal_messagebox.cpp @@ -11,7 +11,7 @@ * GNU General Public License for more details. * * * * You should have received a copy of the GNU General Public License * -* along with this program. If not, see <http://www.gnu.org/licenses/>. * +* along with this program. If not, see <https://www.gnu.org/licenses/>. * ***************************************************************************/ #include <QGridLayout> diff --git a/src/non_modal_messagebox.h b/src/non_modal_messagebox.h index a747c5d..07234a1 100644 --- a/src/non_modal_messagebox.h +++ b/src/non_modal_messagebox.h @@ -11,7 +11,7 @@ * GNU General Public License for more details. * * * * You should have received a copy of the GNU General Public License * -* along with this program. If not, see <http://www.gnu.org/licenses/>. * +* along with this program. If not, see <https://www.gnu.org/licenses/>. * ***************************************************************************/ #ifndef NON_MODAL_MESSAGEBOX_H diff --git a/src/ongetpass.cpp b/src/ongetpass.cpp index 11568e0..eb4b284 100644 --- a/src/ongetpass.cpp +++ b/src/ongetpass.cpp @@ -12,7 +12,7 @@ * GNU General Public License for more details. * * * * You should have received a copy of the GNU General Public License * -* along with this program. If not, see <http://www.gnu.org/licenses/>. * +* along with this program. If not, see <https://www.gnu.org/licenses/>. * ***************************************************************************/ #ifdef HAVE_CONFIG_H diff --git a/src/ongetpass.h b/src/ongetpass.h index 6a88747..862106a 100644 --- a/src/ongetpass.h +++ b/src/ongetpass.h @@ -12,7 +12,7 @@ * GNU General Public License for more details. * * * * You should have received a copy of the GNU General Public License * -* along with this program. If not, see <http://www.gnu.org/licenses/>. * +* along with this program. If not, see <https://www.gnu.org/licenses/>. * ***************************************************************************/ #ifndef ONGETPASS_H diff --git a/src/onmainwindow.cpp b/src/onmainwindow.cpp index eca9451..f3341c9 100644 --- a/src/onmainwindow.cpp +++ b/src/onmainwindow.cpp @@ -12,7 +12,7 @@ * GNU General Public License for more details. * * * * You should have received a copy of the GNU General Public License * -* along with this program. If not, see <http://www.gnu.org/licenses/>. * +* along with this program. If not, see <https://www.gnu.org/licenses/>. * ***************************************************************************/ #include "onmainwindow_privat.h" diff --git a/src/onmainwindow.h b/src/onmainwindow.h index da238d5..816dbd8 100644 --- a/src/onmainwindow.h +++ b/src/onmainwindow.h @@ -12,7 +12,7 @@ * GNU General Public License for more details. * * * * You should have received a copy of the GNU General Public License * -* along with this program. If not, see <http://www.gnu.org/licenses/>. * +* along with this program. If not, see <https://www.gnu.org/licenses/>. * ***************************************************************************/ #ifndef ONMAINWINDOW_H diff --git a/src/onmainwindow_privat.h b/src/onmainwindow_privat.h index 92a3c36..d272f71 100644 --- a/src/onmainwindow_privat.h +++ b/src/onmainwindow_privat.h @@ -12,7 +12,7 @@ * GNU General Public License for more details. * * * * You should have received a copy of the GNU General Public License * -* along with this program. If not, see <http://www.gnu.org/licenses/>. * +* along with this program. If not, see <https://www.gnu.org/licenses/>. * ***************************************************************************/ #ifndef ONMAINWINDOWPRIVAT_H diff --git a/src/printdialog.cpp b/src/printdialog.cpp index d998b87..4d612a4 100644 --- a/src/printdialog.cpp +++ b/src/printdialog.cpp @@ -12,7 +12,7 @@ * GNU General Public License for more details. * * * * You should have received a copy of the GNU General Public License * -* along with this program. If not, see <http://www.gnu.org/licenses/>. * +* along with this program. If not, see <https://www.gnu.org/licenses/>. * ***************************************************************************/ #include "printdialog.h" diff --git a/src/printdialog.h b/src/printdialog.h index 14bec42..7078ad1 100644 --- a/src/printdialog.h +++ b/src/printdialog.h @@ -12,7 +12,7 @@ * GNU General Public License for more details. * * * * You should have received a copy of the GNU General Public License * -* along with this program. If not, see <http://www.gnu.org/licenses/>. * +* along with this program. If not, see <https://www.gnu.org/licenses/>. * ***************************************************************************/ #ifndef PRINTDIALOG_H diff --git a/src/printercmddialog.cpp b/src/printercmddialog.cpp index fe46871..f801edf 100644 --- a/src/printercmddialog.cpp +++ b/src/printercmddialog.cpp @@ -12,7 +12,7 @@ * GNU General Public License for more details. * * * * You should have received a copy of the GNU General Public License * -* along with this program. If not, see <http://www.gnu.org/licenses/>. * +* along with this program. If not, see <https://www.gnu.org/licenses/>. * ***************************************************************************/ #include "printercmddialog.h" diff --git a/src/printercmddialog.h b/src/printercmddialog.h index 2490873..79642ef 100644 --- a/src/printercmddialog.h +++ b/src/printercmddialog.h @@ -12,7 +12,7 @@ * GNU General Public License for more details. * * * * You should have received a copy of the GNU General Public License * -* along with this program. If not, see <http://www.gnu.org/licenses/>. * +* along with this program. If not, see <https://www.gnu.org/licenses/>. * ***************************************************************************/ #ifndef PRINTERCMDDIALOG_H diff --git a/src/printprocess.cpp b/src/printprocess.cpp index abe114a..1324eca 100644 --- a/src/printprocess.cpp +++ b/src/printprocess.cpp @@ -12,7 +12,7 @@ * GNU General Public License for more details. * * * * You should have received a copy of the GNU General Public License * -* along with this program. If not, see <http://www.gnu.org/licenses/>. * +* along with this program. If not, see <https://www.gnu.org/licenses/>. * ***************************************************************************/ #include "x2goclientconfig.h" diff --git a/src/printprocess.h b/src/printprocess.h index 1e6e568..2470391 100644 --- a/src/printprocess.h +++ b/src/printprocess.h @@ -12,7 +12,7 @@ * GNU General Public License for more details. * * * * You should have received a copy of the GNU General Public License * -* along with this program. If not, see <http://www.gnu.org/licenses/>. * +* along with this program. If not, see <https://www.gnu.org/licenses/>. * ***************************************************************************/ #ifndef PRINTPROCESS_H diff --git a/src/printwidget.cpp b/src/printwidget.cpp index 4bdef2f..58a8af7 100644 --- a/src/printwidget.cpp +++ b/src/printwidget.cpp @@ -12,7 +12,7 @@ * GNU General Public License for more details. * * * * You should have received a copy of the GNU General Public License * -* along with this program. If not, see <http://www.gnu.org/licenses/>. * +* along with this program. If not, see <https://www.gnu.org/licenses/>. * ***************************************************************************/ #include "printwidget.h" diff --git a/src/printwidget.h b/src/printwidget.h index 0880c66..4318493 100644 --- a/src/printwidget.h +++ b/src/printwidget.h @@ -12,7 +12,7 @@ * GNU General Public License for more details. * * * * You should have received a copy of the GNU General Public License * -* along with this program. If not, see <http://www.gnu.org/licenses/>. * +* along with this program. If not, see <https://www.gnu.org/licenses/>. * ***************************************************************************/ #ifndef PRINTWIDGET_H diff --git a/src/sessionbutton.cpp b/src/sessionbutton.cpp index f9bf371..0bbbdc9 100644 --- a/src/sessionbutton.cpp +++ b/src/sessionbutton.cpp @@ -12,7 +12,7 @@ * GNU General Public License for more details. * * * * You should have received a copy of the GNU General Public License * -* along with this program. If not, see <http://www.gnu.org/licenses/>. * +* along with this program. If not, see <https://www.gnu.org/licenses/>. * ***************************************************************************/ #include "sessionbutton.h" diff --git a/src/sessionbutton.h b/src/sessionbutton.h index fd9101a..6e87337 100644 --- a/src/sessionbutton.h +++ b/src/sessionbutton.h @@ -12,7 +12,7 @@ * GNU General Public License for more details. * * * * You should have received a copy of the GNU General Public License * -* along with this program. If not, see <http://www.gnu.org/licenses/>. * +* along with this program. If not, see <https://www.gnu.org/licenses/>. * ***************************************************************************/ #ifndef SESSIONBUTTON_H diff --git a/src/sessionexplorer.cpp b/src/sessionexplorer.cpp index 4cd022b..fe884f6 100644 --- a/src/sessionexplorer.cpp +++ b/src/sessionexplorer.cpp @@ -12,7 +12,7 @@ * GNU General Public License for more details. * * * * You should have received a copy of the GNU General Public License * -* along with this program. If not, see <http://www.gnu.org/licenses/>. * +* along with this program. If not, see <https://www.gnu.org/licenses/>. * ***************************************************************************/ #include "sessionexplorer.h" diff --git a/src/sessionexplorer.h b/src/sessionexplorer.h index 6fa70b1..c526fef 100644 --- a/src/sessionexplorer.h +++ b/src/sessionexplorer.h @@ -12,7 +12,7 @@ * GNU General Public License for more details. * * * * You should have received a copy of the GNU General Public License * -* along with this program. If not, see <http://www.gnu.org/licenses/>. * +* along with this program. If not, see <https://www.gnu.org/licenses/>. * ***************************************************************************/ #ifndef SESSIONEXPLORER_H diff --git a/src/sessionmanagedialog.cpp b/src/sessionmanagedialog.cpp index 2d57424..ee1eda6 100644 --- a/src/sessionmanagedialog.cpp +++ b/src/sessionmanagedialog.cpp @@ -12,7 +12,7 @@ * GNU General Public License for more details. * * * * You should have received a copy of the GNU General Public License * -* along with this program. If not, see <http://www.gnu.org/licenses/>. * +* along with this program. If not, see <https://www.gnu.org/licenses/>. * ***************************************************************************/ #include "x2goclientconfig.h" diff --git a/src/sessionmanagedialog.h b/src/sessionmanagedialog.h index c9f0f5e..9d4bfd2 100644 --- a/src/sessionmanagedialog.h +++ b/src/sessionmanagedialog.h @@ -12,7 +12,7 @@ * GNU General Public License for more details. * * * * You should have received a copy of the GNU General Public License * -* along with this program. If not, see <http://www.gnu.org/licenses/>. * +* along with this program. If not, see <https://www.gnu.org/licenses/>. * ***************************************************************************/ #ifndef SESSIONMANAGEDIALOG_H diff --git a/src/sessionwidget.cpp b/src/sessionwidget.cpp index 97e310e..636d67e 100644 --- a/src/sessionwidget.cpp +++ b/src/sessionwidget.cpp @@ -12,7 +12,7 @@ * GNU General Public License for more details. * * * * You should have received a copy of the GNU General Public License * -* along with this program. If not, see <http://www.gnu.org/licenses/>. * +* along with this program. If not, see <https://www.gnu.org/licenses/>. * ***************************************************************************/ #include "sessionwidget.h" diff --git a/src/sessionwidget.h b/src/sessionwidget.h index e30e00e..bbc940e 100644 --- a/src/sessionwidget.h +++ b/src/sessionwidget.h @@ -12,7 +12,7 @@ * GNU General Public License for more details. * * * * You should have received a copy of the GNU General Public License * -* along with this program. If not, see <http://www.gnu.org/licenses/>. * +* along with this program. If not, see <https://www.gnu.org/licenses/>. * ***************************************************************************/ #ifndef SESSIONWIDGET_H diff --git a/src/settingswidget.cpp b/src/settingswidget.cpp index 5715c88..3b8a9c9 100644 --- a/src/settingswidget.cpp +++ b/src/settingswidget.cpp @@ -12,7 +12,7 @@ * GNU General Public License for more details. * * * * You should have received a copy of the GNU General Public License * -* along with this program. If not, see <http://www.gnu.org/licenses/>. * +* along with this program. If not, see <https://www.gnu.org/licenses/>. * ***************************************************************************/ #include "settingswidget.h" diff --git a/src/settingswidget.h b/src/settingswidget.h index 01e081b..a58d429 100644 --- a/src/settingswidget.h +++ b/src/settingswidget.h @@ -12,7 +12,7 @@ * GNU General Public License for more details. * * * * You should have received a copy of the GNU General Public License * -* along with this program. If not, see <http://www.gnu.org/licenses/>. * +* along with this program. If not, see <https://www.gnu.org/licenses/>. * ***************************************************************************/ #ifndef SETTINGSWIDGET_H diff --git a/src/sharewidget.cpp b/src/sharewidget.cpp index 5d8b35b..5502069 100644 --- a/src/sharewidget.cpp +++ b/src/sharewidget.cpp @@ -12,7 +12,7 @@ * GNU General Public License for more details. * * * * You should have received a copy of the GNU General Public License * -* along with this program. If not, see <http://www.gnu.org/licenses/>. * +* along with this program. If not, see <https://www.gnu.org/licenses/>. * ***************************************************************************/ #include "sharewidget.h" diff --git a/src/sharewidget.h b/src/sharewidget.h index ad8dac7..22ee358 100644 --- a/src/sharewidget.h +++ b/src/sharewidget.h @@ -12,7 +12,7 @@ * GNU General Public License for more details. * * * * You should have received a copy of the GNU General Public License * -* along with this program. If not, see <http://www.gnu.org/licenses/>. * +* along with this program. If not, see <https://www.gnu.org/licenses/>. * ***************************************************************************/ #ifndef SHAREWIDGET_H diff --git a/src/sshmasterconnection.cpp b/src/sshmasterconnection.cpp index 7c2f91b..e3c252f 100644 --- a/src/sshmasterconnection.cpp +++ b/src/sshmasterconnection.cpp @@ -12,7 +12,7 @@ * GNU General Public License for more details. * * * * You should have received a copy of the GNU General Public License * -* along with this program. If not, see <http://www.gnu.org/licenses/>. * +* along with this program. If not, see <https://www.gnu.org/licenses/>. * ***************************************************************************/ #include "x2goclientconfig.h" diff --git a/src/sshmasterconnection.h b/src/sshmasterconnection.h index ad6776b..69bfa0d 100644 --- a/src/sshmasterconnection.h +++ b/src/sshmasterconnection.h @@ -12,7 +12,7 @@ * GNU General Public License for more details. * * * * You should have received a copy of the GNU General Public License * -* along with this program. If not, see <http://www.gnu.org/licenses/>. * +* along with this program. If not, see <https://www.gnu.org/licenses/>. * ***************************************************************************/ #ifndef SSHMASTERCONNECTION_H diff --git a/src/sshprocess.cpp b/src/sshprocess.cpp index a5bb5cf..70c3b1c 100644 --- a/src/sshprocess.cpp +++ b/src/sshprocess.cpp @@ -12,7 +12,7 @@ * GNU General Public License for more details. * * * * You should have received a copy of the GNU General Public License * -* along with this program. If not, see <http://www.gnu.org/licenses/>. * +* along with this program. If not, see <https://www.gnu.org/licenses/>. * ***************************************************************************/ #include "x2goclientconfig.h" diff --git a/src/sshprocess.h b/src/sshprocess.h index e8df1ea..191cd3f 100644 --- a/src/sshprocess.h +++ b/src/sshprocess.h @@ -12,7 +12,7 @@ * GNU General Public License for more details. * * * * You should have received a copy of the GNU General Public License * -* along with this program. If not, see <http://www.gnu.org/licenses/>. * +* along with this program. If not, see <https://www.gnu.org/licenses/>. * ***************************************************************************/ #ifndef SSHPROCESS_H diff --git a/src/userbutton.cpp b/src/userbutton.cpp index 712ceac..ede550a 100644 --- a/src/userbutton.cpp +++ b/src/userbutton.cpp @@ -12,7 +12,7 @@ * GNU General Public License for more details. * * * * You should have received a copy of the GNU General Public License * -* along with this program. If not, see <http://www.gnu.org/licenses/>. * +* along with this program. If not, see <https://www.gnu.org/licenses/>. * ***************************************************************************/ #include "x2goclientconfig.h" diff --git a/src/userbutton.h b/src/userbutton.h index d07bf3d..6faff92 100644 --- a/src/userbutton.h +++ b/src/userbutton.h @@ -12,7 +12,7 @@ * GNU General Public License for more details. * * * * You should have received a copy of the GNU General Public License * -* along with this program. If not, see <http://www.gnu.org/licenses/>. * +* along with this program. If not, see <https://www.gnu.org/licenses/>. * ***************************************************************************/ #ifndef USERBUTTON_H diff --git a/src/version.h b/src/version.h index a788b52..731db8f 100644 --- a/src/version.h +++ b/src/version.h @@ -13,7 +13,7 @@ * GNU General Public License for more details. * * * * You should have received a copy of the GNU General Public License * -* along with this program. If not, see <http://www.gnu.org/licenses/>. * +* along with this program. If not, see <https://www.gnu.org/licenses/>. * ***************************************************************************/ #ifndef VERSION_H diff --git a/src/wapi.cpp b/src/wapi.cpp index cc59763..b5d485b 100644 --- a/src/wapi.cpp +++ b/src/wapi.cpp @@ -12,7 +12,7 @@ * GNU General Public License for more details. * * * * You should have received a copy of the GNU General Public License * -* along with this program. If not, see <http://www.gnu.org/licenses/>. * +* along with this program. If not, see <https://www.gnu.org/licenses/>. * ***************************************************************************/ #ifndef _WIN32_WINDOWS diff --git a/src/wapi.h b/src/wapi.h index 1db53b3..8ad19e1 100644 --- a/src/wapi.h +++ b/src/wapi.h @@ -12,7 +12,7 @@ * GNU General Public License for more details. * * * * You should have received a copy of the GNU General Public License * -* along with this program. If not, see <http://www.gnu.org/licenses/>. * +* along with this program. If not, see <https://www.gnu.org/licenses/>. * ***************************************************************************/ #ifndef _WAPI_H diff --git a/src/x2goclient.cpp b/src/x2goclient.cpp index 9879142..32801c3 100644 --- a/src/x2goclient.cpp +++ b/src/x2goclient.cpp @@ -13,7 +13,7 @@ * GNU General Public License for more details. * * * * You should have received a copy of the GNU General Public License * -* along with this program. If not, see <http://www.gnu.org/licenses/>. * +* along with this program. If not, see <https://www.gnu.org/licenses/>. * ***************************************************************************/ #include <iostream> diff --git a/src/x2goclientconfig.h b/src/x2goclientconfig.h index fb55a81..b29f576 100644 --- a/src/x2goclientconfig.h +++ b/src/x2goclientconfig.h @@ -12,7 +12,7 @@ * GNU General Public License for more details. * * * * You should have received a copy of the GNU General Public License * -* along with this program. If not, see <http://www.gnu.org/licenses/>. * +* along with this program. If not, see <https://www.gnu.org/licenses/>. * ***************************************************************************/ #if !defined(_X2GOCLIENT_CONFIG_H_) diff --git a/src/x2gologdebug.cpp b/src/x2gologdebug.cpp index c03d18d..d35e27a 100644 --- a/src/x2gologdebug.cpp +++ b/src/x2gologdebug.cpp @@ -12,7 +12,7 @@ * GNU General Public License for more details. * * * * You should have received a copy of the GNU General Public License * -* along with this program. If not, see <http://www.gnu.org/licenses/>. * +* along with this program. If not, see <https://www.gnu.org/licenses/>. * ***************************************************************************/ #include "x2gologdebug.h" diff --git a/src/x2gologdebug.h b/src/x2gologdebug.h index bf065e7..85e6bac 100644 --- a/src/x2gologdebug.h +++ b/src/x2gologdebug.h @@ -12,7 +12,7 @@ * GNU General Public License for more details. * * * * You should have received a copy of the GNU General Public License * -* along with this program. If not, see <http://www.gnu.org/licenses/>. * +* along with this program. If not, see <https://www.gnu.org/licenses/>. * ***************************************************************************/ #ifndef X2GOLOGDEBUG_H diff --git a/src/x2gosettings.cpp b/src/x2gosettings.cpp index b8908dc..2dfb5d7 100644 --- a/src/x2gosettings.cpp +++ b/src/x2gosettings.cpp @@ -12,7 +12,7 @@ * GNU General Public License for more details. * * * * You should have received a copy of the GNU General Public License * -* along with this program. If not, see <http://www.gnu.org/licenses/>. * +* along with this program. If not, see <https://www.gnu.org/licenses/>. * ***************************************************************************/ #include "x2gosettings.h" diff --git a/src/x2gosettings.h b/src/x2gosettings.h index 3905198..0fc7598 100644 --- a/src/x2gosettings.h +++ b/src/x2gosettings.h @@ -12,7 +12,7 @@ * GNU General Public License for more details. * * * * You should have received a copy of the GNU General Public License * -* along with this program. If not, see <http://www.gnu.org/licenses/>. * +* along with this program. If not, see <https://www.gnu.org/licenses/>. * ***************************************************************************/ #ifndef X2GOSETTINGS_H diff --git a/src/x2goutils.cpp b/src/x2goutils.cpp index 35a5992..ce0ae4c 100644 --- a/src/x2goutils.cpp +++ b/src/x2goutils.cpp @@ -13,7 +13,7 @@ * GNU General Public License for more details. * * * * You should have received a copy of the GNU General Public License * -* along with this program. If not, see <http://www.gnu.org/licenses/>. * +* along with this program. If not, see <https://www.gnu.org/licenses/>. * ***************************************************************************/ #include <vector> diff --git a/src/x2goutils.h b/src/x2goutils.h index 8a406c7..e0051b4 100644 --- a/src/x2goutils.h +++ b/src/x2goutils.h @@ -13,7 +13,7 @@ * GNU General Public License for more details. * * * * You should have received a copy of the GNU General Public License * -* along with this program. If not, see <http://www.gnu.org/licenses/>. * +* along with this program. If not, see <https://www.gnu.org/licenses/>. * ***************************************************************************/ #ifndef X2GOUTILS_H diff --git a/src/xsettingswidget.cpp b/src/xsettingswidget.cpp index 2901c4f..d97a61d 100644 --- a/src/xsettingswidget.cpp +++ b/src/xsettingswidget.cpp @@ -12,7 +12,7 @@ * GNU General Public License for more details. * * * * You should have received a copy of the GNU General Public License * -* along with this program. If not, see <http://www.gnu.org/licenses/>. * +* along with this program. If not, see <https://www.gnu.org/licenses/>. * ***************************************************************************/ #include "xsettingswidget.h" #include "x2gosettings.h" diff --git a/src/xsettingswidget.h b/src/xsettingswidget.h index 4376d7c..aa9d8ff 100644 --- a/src/xsettingswidget.h +++ b/src/xsettingswidget.h @@ -12,7 +12,7 @@ * GNU General Public License for more details. * * * * You should have received a copy of the GNU General Public License * -* along with this program. If not, see <http://www.gnu.org/licenses/>. * +* along with this program. If not, see <https://www.gnu.org/licenses/>. * ***************************************************************************/ #ifndef XSETTINGSWIDGET_H diff --git a/x2goclient.spec b/x2goclient.spec index 98800d2..a5f293b 100644 --- a/x2goclient.spec +++ b/x2goclient.spec @@ -11,8 +11,8 @@ Group: Applications/Communications License: GPLv2+ %endif -URL: http://www.x2go.org -Source0: http://code.x2go.org/releases/source/%{name}/%{name}-%{version}.tar.gz +URL: https://www.x2go.org +Source0: https://code.x2go.org/releases/source/%{name}/%{name}-%{version}.tar.gz Source1: x2goclient-rpmlintrc BuildRequires: cups-devel diff --git a/x2gohelper/x2gohelper.cpp b/x2gohelper/x2gohelper.cpp index d321bef..9d9d8ea 100644 --- a/x2gohelper/x2gohelper.cpp +++ b/x2gohelper/x2gohelper.cpp @@ -12,7 +12,7 @@ * GNU General Public License for more details. * * * * You should have received a copy of the GNU General Public License * -* along with this program. If not, see <http://www.gnu.org/licenses/>. * +* along with this program. If not, see <https://www.gnu.org/licenses/>. * ***************************************************************************/ #include <windows.h> #include <TlHelp32.h> -- Alioth's /home/x2go-admin/maintenancescripts/git/hooks/post-receive-email on /srv/git/code.x2go.org/x2goclient.git
This is an automated email from the git hooks/post-receive script. x2go pushed a commit to branch master in repository x2goclient. commit df16a018ae05f127ca62dc2c7833cf3452297570 Author: Mihai Moldovan <ionic@ionic.de> Date: Wed Mar 14 02:19:30 2018 +0100 debian/rules: remove x2goclient_*.qm files removal. --- debian/changelog | 1 + debian/rules | 2 -- 2 files changed, 1 insertion(+), 2 deletions(-) diff --git a/debian/changelog b/debian/changelog index 0e53d09..450013e 100644 --- a/debian/changelog +++ b/debian/changelog @@ -39,6 +39,7 @@ x2goclient (4.1.2.0-0x2go1) UNRELEASED; urgency=medium - Remove plugin references. * debian/rules: - Remove plugin references. + - Remove x2goclient_*.qm files removal. * debian/control: - Convert plugin packages to dummy transitional packages with no dependencies, remove other plugin references. diff --git a/debian/rules b/debian/rules index f2e1197..4b301a0 100755 --- a/debian/rules +++ b/debian/rules @@ -15,8 +15,6 @@ override_dh_auto_configure: override_dh_auto_clean: dh_auto_clean - # clean stray .qm files that are not handled by clean rule in upstream Makefile - rm -Rf res/i18n/x2goclient_*.qm rm -f res/txt/changelog override_dh_strip: -- Alioth's /home/x2go-admin/maintenancescripts/git/hooks/post-receive-email on /srv/git/code.x2go.org/x2goclient.git
This is an automated email from the git hooks/post-receive script. x2go pushed a commit to branch master in repository x2goclient. commit dd26e302266a227442eb3a1beb40d1b0febbedce Author: Mihai Moldovan <ionic@ionic.de> Date: Wed Mar 14 02:18:00 2018 +0100 Makefile: remove x2goclient_*.qm files in clean rule. --- Makefile | 1 + debian/changelog | 1 + 2 files changed, 2 insertions(+) diff --git a/Makefile b/Makefile index 4401ce0..a87b21f 100755 --- a/Makefile +++ b/Makefile @@ -78,6 +78,7 @@ clean: clean_client clean_man find . -maxdepth 3 -name 'moc_*.cpp' -exec rm -vf {} + -type f find . -maxdepth 3 -name 'ui_*.h' -exec rm -vf {} + -type f find . -maxdepth 3 -name 'qrc_*.cpp' -exec rm -vf {} + -type f + find . -maxdepth 3 -name 'x2goclient_*.qm' -exec rm -vf {} + -type f rm -f x2goclient rm -f x2goclient.tag rm -f res/txt/changelog diff --git a/debian/changelog b/debian/changelog index ecf0742..0e53d09 100644 --- a/debian/changelog +++ b/debian/changelog @@ -34,6 +34,7 @@ x2goclient (4.1.2.0-0x2go1) UNRELEASED; urgency=medium - misc: change http:// to https:// where appropriate, but in actual code and translation files for now. - Makefile: remove plugin references. + - Makefile: remove x2goclient_*.qm files in clean rule. * x2goclient.spec: - Remove plugin references. * debian/rules: -- Alioth's /home/x2go-admin/maintenancescripts/git/hooks/post-receive-email on /srv/git/code.x2go.org/x2goclient.git
This is an automated email from the git hooks/post-receive script. x2go pushed a commit to branch master in repository x2goclient. commit 84fc6e45a19df5b96b7a6e69546718968c36c268 Author: Mihai Moldovan <ionic@ionic.de> Date: Wed Mar 14 02:15:51 2018 +0100 Makefile: remove plugin references. --- Makefile | 49 ++++--------------------------------------------- debian/changelog | 1 + 2 files changed, 5 insertions(+), 45 deletions(-) diff --git a/Makefile b/Makefile index a7656e2..4401ce0 100755 --- a/Makefile +++ b/Makefile @@ -4,9 +4,6 @@ TOP_DIR=$(CURDIR) CLIENT_DIR=$(TOP_DIR)/client_build CLIENT_BINARY=$(CLIENT_DIR)/x2goclient -PLUGIN_DIR=$(TOP_DIR)/plugin_build -PLUGIN_BINARY=$(PLUGIN_DIR)/libx2goplugin.so - SHELL=/bin/bash INSTALL_DIR=install -d -o root -g root -m 755 @@ -23,7 +20,6 @@ ETCDIR=/etc/x2go BINDIR=$(PREFIX)/bin SHAREDIR=$(PREFIX)/share MANDIR=$(SHAREDIR)/man -MOZPLUGDIR=$(PREFIX)/lib/mozilla/plugins QMAKE_BINARY=qmake-qt4 LRELEASE_BINARY=lrelease-qt4 QMAKE_OPTS= @@ -66,26 +62,18 @@ MAKEOVERRIDES= all: build -build: build_man build_pluginprovider +build: build_man $(MAKE) build_client - $(MAKE) build_plugin build_client: $(LRELEASE_BINARY) x2goclient.pro mkdir -p $(CLIENT_DIR) && cd $(CLIENT_DIR) && $(QMAKE_BINARY) QMAKE_CFLAGS="${CPPFLAGS} ${CFLAGS}" QMAKE_CXXFLAGS="${CPPFLAGS} ${CXXFLAGS}" QMAKE_LFLAGS="${LDFLAGS}" $(QMAKE_OPTS) ../x2goclient.pro cd $(CLIENT_DIR) && $(MAKE) -build_plugin: - $(LRELEASE_BINARY) x2goclient.pro - mkdir -p $(PLUGIN_DIR) && cd $(PLUGIN_DIR) && X2GO_CLIENT_TARGET=plugin $(QMAKE_BINARY) QMAKE_CFLAGS="${CPPFLAGS} ${CFLAGS}" QMAKE_CXXFLAGS="${CPPFLAGS} ${CXXFLAGS}" QMAKE_LFLAGS="${LDFLAGS}" $(QMAKE_OPTS) ../x2goclient.pro - cd $(PLUGIN_DIR) && $(MAKE) - -build_pluginprovider: - build_man: ${MAKE} -f Makefile.man2html build -clean: clean_client clean_plugin clean_man clean_pluginprovider +clean: clean_client clean_man find . -maxdepth 3 -name '*.o' -exec rm -vf {} + -type f find . -maxdepth 3 -name 'moc_*.cpp' -exec rm -vf {} + -type f find . -maxdepth 3 -name 'ui_*.h' -exec rm -vf {} + -type f @@ -98,15 +86,10 @@ clean: clean_client clean_plugin clean_man clean_pluginprovider clean_client: rm -fr $(CLIENT_DIR) -clean_plugin: - rm -fr $(PLUGIN_DIR) - -clean_pluginprovider: - clean_man: make -f Makefile.man2html clean -install: install_client install_plugin install_man install_pluginprovider +install: install_client install_man install_client: $(INSTALL_DIR) $(DESTDIR)$(BINDIR)/ @@ -126,24 +109,13 @@ install_client: $(INSTALL_FILE) res/img/icons/64x64/x2goclient.png $(DESTDIR)$(SHAREDIR)/icons/hicolor/64x64/apps/x2goclient.png $(INSTALL_FILE) res/img/icons/32x32/x2goclient.png $(DESTDIR)$(SHAREDIR)/icons/hicolor/32x32/apps/x2goclient.png -install_plugin: - $(INSTALL_DIR) $(DESTDIR)$(MOZPLUGDIR)/ - $(INSTALL_PROGRAM) $(PLUGIN_DIR)/libx2goplugin.so $(DESTDIR)$(MOZPLUGDIR)/libx2goplugin.so - -install_pluginprovider: - $(INSTALL_DIR) $(DESTDIR)$(ETCDIR)/plugin-provider - $(INSTALL_FILE) provider/etc/x2goplugin-apache.conf $(DESTDIR)$(ETCDIR)/x2goplugin-apache.conf - $(INSTALL_FILE) provider/share/x2goplugin.html $(DESTDIR)$(ETCDIR)/plugin-provider/x2goplugin.html - $(INSTALL_DIR) $(DESTDIR)$(SHAREDIR)/x2go/plugin/ - $(INSTALL_SYMLINK) ../../../../$(ETCDIR)/plugin-provider/x2goplugin.html $(DESTDIR)$(SHAREDIR)/x2go/plugin/x2goplugin.html - install_man: $(INSTALL_DIR) $(DESTDIR)$(MANDIR)/ $(INSTALL_DIR) $(DESTDIR)$(MANDIR)/man1 $(INSTALL_FILE) man/man1/x2goclient.1 $(DESTDIR)$(MANDIR)/man1/x2goclient.1 gzip -f $(DESTDIR)$(MANDIR)/man1/x2goclient.1 -uninstall: uninstall_client uninstall_plugin uninstall_man +uninstall: uninstall_client uninstall_man uninstall_client: $(RM_FILE) $(BINDIR)/x2goclient @@ -162,19 +134,6 @@ uninstall_client: $(RM_DIR) $(SHAREDIR)/icons/hicolor/64x64/apps $(RM_DIR) $(SHAREDIR)/icons/hicolor/32x32/apps -uninstall_plugin: - $(RM_FILE) $(MOZPLUGDIR)/libx2goplugin.so - $(RM_DIR) $(MOZPLUGDIR)/ - -uninstall_pluginprovider: - $(RM_FILE) $(ETCDIR)/x2goplugin-apache.conf - $(RM_FILE) $(ETCDIR)/plugin-provider/x2goplugin.html - $(RM_DIR) $(ETCDIR)/plugin-provider - $(RM_DIR) $(ETCDIR) - $(RM_FILE) $(SHAREDIR)/x2go/plugin/x2goplugin.html - $(RM_DIR) $(SHAREDIR)/x2go/plugin/ - $(RM_DIR) $(SHAREDIR)/x2go/ - uninstall_man: $(RM_FILE) $(MANDIR)/man1/x2goclient.1.gz $(RM_DIR) $(MANDIR)/man1 diff --git a/debian/changelog b/debian/changelog index 8124940..ecf0742 100644 --- a/debian/changelog +++ b/debian/changelog @@ -33,6 +33,7 @@ x2goclient (4.1.2.0-0x2go1) UNRELEASED; urgency=medium - x2goclient.pro: remove plugin references. - misc: change http:// to https:// where appropriate, but in actual code and translation files for now. + - Makefile: remove plugin references. * x2goclient.spec: - Remove plugin references. * debian/rules: -- Alioth's /home/x2go-admin/maintenancescripts/git/hooks/post-receive-email on /srv/git/code.x2go.org/x2goclient.git
This is an automated email from the git hooks/post-receive script. x2go pushed a commit to branch master in repository x2goclient. commit 9274e2c679a41a8c3cdbb8ac8c1c6fb241532fc5 Author: Mihai Moldovan <ionic@ionic.de> Date: Wed Mar 14 02:20:50 2018 +0100 x2gobrowserplugin-2.4_1/: remove. --- debian/changelog | 1 + x2gobrowserplugin-2.4_1/src/qtbrowserplugin.cpp | 1703 -------------------- x2gobrowserplugin-2.4_1/src/qtbrowserplugin.def | 4 - x2gobrowserplugin-2.4_1/src/qtbrowserplugin.h | 176 -- x2gobrowserplugin-2.4_1/src/qtbrowserplugin.pri | 74 - .../src/qtbrowserplugin_mac.cpp | 560 ------- x2gobrowserplugin-2.4_1/src/qtbrowserplugin_p.h | 94 -- .../src/qtbrowserplugin_win.cpp | 194 --- .../src/qtbrowserplugin_x11.cpp | 150 -- x2gobrowserplugin-2.4_1/src/qtbrowserpluginax.def | 9 - x2gobrowserplugin-2.4_1/src/qtnpapi.h | 555 ------- x2gobrowserplugin-2.4_1/src/res/x2goplugin.rc | 37 - 12 files changed, 1 insertion(+), 3556 deletions(-) diff --git a/debian/changelog b/debian/changelog index 450013e..dfe23cc 100644 --- a/debian/changelog +++ b/debian/changelog @@ -35,6 +35,7 @@ x2goclient (4.1.2.0-0x2go1) UNRELEASED; urgency=medium and translation files for now. - Makefile: remove plugin references. - Makefile: remove x2goclient_*.qm files in clean rule. + - x2gobrowserplugin-2.4_1/: remove. * x2goclient.spec: - Remove plugin references. * debian/rules: diff --git a/x2gobrowserplugin-2.4_1/src/qtbrowserplugin.cpp b/x2gobrowserplugin-2.4_1/src/qtbrowserplugin.cpp deleted file mode 100644 index 06010d1..0000000 --- a/x2gobrowserplugin-2.4_1/src/qtbrowserplugin.cpp +++ /dev/null @@ -1,1703 +0,0 @@ -/**************************************************************************** -** -** Copyright (C) 2009 Nokia Corporation and/or its subsidiary(-ies). -** All rights reserved. -** Contact: Nokia Corporation (qt-info@nokia.com) -** -** This file is part of a Qt Solutions component. -** -** You may use this file under the terms of the BSD license as follows: -** -** "Redistribution and use in source and binary forms, with or without -** modification, are permitted provided that the following conditions are -** met: -** * Redistributions of source code must retain the above copyright -** notice, this list of conditions and the following disclaimer. -** * Redistributions in binary form must reproduce the above copyright -** notice, this list of conditions and the following disclaimer in -** the documentation and/or other materials provided with the -** distribution. -** * Neither the name of Nokia Corporation and its Subsidiary(-ies) nor -** the names of its contributors may be used to endorse or promote -** products derived from this software without specific prior written -** permission. -** -** THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS -** "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT -** LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR -** A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT -** OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, -** SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT -** LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, -** DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY -** THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT -** (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE -** OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE." -** -****************************************************************************/ - -#include <QtGui> - -#include "qtnpapi.h" - -#include "qtbrowserplugin.h" -#include "qtbrowserplugin_p.h" - -#ifndef WINAPI -# ifdef Q_WS_WIN -# define WINAPI __stdcall -# else -# define WINAPI -# endif -#endif - -#ifdef Q_WS_X11 -# ifdef Bool -# undef Bool -# endif - -/* -static void debuginfo(const QString &str) -{ - static bool inited = false; - QFile file("/tmp/qnsdebug.txt"); - if (file.open(QFile::WriteOnly | QFile::Append)) { - if (!inited) { - file.write("\n\n*** New run started ***\n"); - inited = true; - } - file.write(qtNPFactory()->pluginName().toLatin1() + ": " + str.toLatin1() + '\n'); - file.close(); - } -} -*/ - -#endif - -static QtNPFactory *qNP = 0; -static NPNetscapeFuncs *qNetscapeFuncs = 0; - -// The single global plugin -QtNPFactory *qtNPFactory() -{ - extern QtNPFactory *qtns_instantiate(); - - if (!qNP) { - qNP = qtns_instantiate(); - } - - return qNP; -} - -// NPN functions, forwarding to function pointers provided by browser -void NPN_Version(int* plugin_major, int* plugin_minor, int* netscape_major, int* netscape_minor) -{ - Q_ASSERT(qNetscapeFuncs); - *plugin_major = NP_VERSION_MAJOR; - *plugin_minor = NP_VERSION_MINOR; - *netscape_major = qNetscapeFuncs->version >> 8; // Major version is in high byte - *netscape_minor = qNetscapeFuncs->version & 0xFF; // Minor version is in low byte -} - -#define NPN_Prolog(x) \ - Q_ASSERT(qNetscapeFuncs); \ - Q_ASSERT(qNetscapeFuncs->x); \ - - -const char *NPN_UserAgent(NPP instance) -{ - NPN_Prolog(uagent); - return FIND_FUNCTION_POINTER(NPN_UserAgentFP, qNetscapeFuncs->uagent)(instance); -} - -void NPN_Status(NPP instance, const char* message) -{ - NPN_Prolog(status); - FIND_FUNCTION_POINTER(NPN_StatusFP, qNetscapeFuncs->status)(instance, message); -} - -NPError NPN_GetURL(NPP instance, const char* url, const char* window) -{ - NPN_Prolog(geturl); - return FIND_FUNCTION_POINTER(NPN_GetURLFP, qNetscapeFuncs->geturl)(instance, url, window); -} - -NPError NPN_GetURLNotify(NPP instance, const char* url, const char* window, void* notifyData) -{ - if ((qNetscapeFuncs->version & 0xFF) < NPVERS_HAS_NOTIFICATION) - return NPERR_INCOMPATIBLE_VERSION_ERROR; - - NPN_Prolog(geturlnotify); - return FIND_FUNCTION_POINTER(NPN_GetURLNotifyFP, qNetscapeFuncs->geturlnotify)(instance, url, window, notifyData); -} - -NPError NPN_PostURLNotify(NPP instance, const char* url, const char* window, uint32 len, const char* buf, NPBool file, void* notifyData) -{ - if ((qNetscapeFuncs->version & 0xFF) < NPVERS_HAS_NOTIFICATION) - return NPERR_INCOMPATIBLE_VERSION_ERROR; - - NPN_Prolog(posturlnotify); - return FIND_FUNCTION_POINTER(NPN_PostURLNotifyFP, qNetscapeFuncs->posturlnotify)(instance, url, window, len, buf, file, notifyData); -} - -void* NPN_MemAlloc(uint32 size) -{ - NPN_Prolog(memalloc); - return FIND_FUNCTION_POINTER(NPN_MemAllocFP, qNetscapeFuncs->memalloc)(size); -} - -void NPN_MemFree(void* ptr) -{ - NPN_Prolog(memfree); - FIND_FUNCTION_POINTER(NPN_MemFreeFP, qNetscapeFuncs->memfree)(ptr); -} - -uint32 NPN_MemFlush(uint32 size) -{ - NPN_Prolog(memflush); - return FIND_FUNCTION_POINTER(NPN_MemFlushFP, qNetscapeFuncs->memflush)(size); -} - -NPError NPN_GetValue(NPP instance, NPNVariable variable, void *ret_value) -{ - NPN_Prolog(getvalue); - return FIND_FUNCTION_POINTER(NPN_GetValueFP, qNetscapeFuncs->getvalue)(instance, variable, ret_value); -} - -NPError NPN_SetValue(NPP instance, NPPVariable variable, void *ret_value) -{ - NPN_Prolog(setvalue); - return FIND_FUNCTION_POINTER(NPN_SetValueFP, qNetscapeFuncs->setvalue)(instance, variable, ret_value); -} - -NPIdentifier NPN_GetStringIdentifier(const char* name) -{ - NPN_Prolog(getstringidentifier); - return FIND_FUNCTION_POINTER(NPN_GetStringIdentifierFP, qNetscapeFuncs->getstringidentifier)(name); -} - -void NPN_GetStringIdentifiers(const char** names, int32 nameCount, NPIdentifier* identifiers) -{ - NPN_Prolog(getstringidentifiers); - FIND_FUNCTION_POINTER(NPN_GetStringIdentifiersFP, qNetscapeFuncs->getstringidentifiers)(names, nameCount, identifiers); -} - -NPIdentifier NPN_GetIntIdentifier(int32 intid) -{ - NPN_Prolog(getintidentifier); - return FIND_FUNCTION_POINTER(NPN_GetIntIdentifierFP, qNetscapeFuncs->getintidentifier)(intid); -} - -bool NPN_IdentifierIsString(NPIdentifier identifier) -{ - NPN_Prolog(identifierisstring); - return FIND_FUNCTION_POINTER(NPN_IdentifierIsStringFP, qNetscapeFuncs->identifierisstring)(identifier); -} - -char* NPN_UTF8FromIdentifier(NPIdentifier identifier) -{ - NPN_Prolog(utf8fromidentifier); - return FIND_FUNCTION_POINTER(NPN_UTF8FromIdentifierFP, qNetscapeFuncs->utf8fromidentifier)(identifier); -} - -int32 NPN_IntFromIdentifier(NPIdentifier identifier) -{ - NPN_Prolog(intfromidentifier); - return FIND_FUNCTION_POINTER(NPN_IntFromIdentifierFP, qNetscapeFuncs->intfromidentifier)(identifier); -} - -NPObject* NPN_CreateObject(NPP npp, NPClass *aClass) -{ - NPN_Prolog(createobject); - return FIND_FUNCTION_POINTER(NPN_CreateObjectFP, qNetscapeFuncs->createobject)(npp, aClass); -} - -NPObject* NPN_RetainObject(NPObject *obj) -{ - NPN_Prolog(retainobject); - return FIND_FUNCTION_POINTER(NPN_RetainObjectFP, qNetscapeFuncs->retainobject)(obj); -} - -void NPN_ReleaseObject(NPObject *obj) -{ - NPN_Prolog(releaseobject); - FIND_FUNCTION_POINTER(NPN_ReleaseObjectFP, qNetscapeFuncs->releaseobject)(obj); -} - -// Scripting implementation (QObject calling JavaScript in browser) - we don't use those -bool NPN_Invoke(NPP npp, NPObject* obj, NPIdentifier methodName, const NPVariant *args, int32 argCount, NPVariant *result) -{ - NPN_Prolog(invoke); - return FIND_FUNCTION_POINTER(NPN_InvokeFP, qNetscapeFuncs->invoke)(npp, obj, methodName, args, argCount, result); -} - -bool NPN_InvokeDefault(NPP npp, NPObject* obj, const NPVariant *args, int32 argCount, NPVariant *result) -{ - NPN_Prolog(invokedefault); - return FIND_FUNCTION_POINTER(NPN_InvokeDefaultFP, qNetscapeFuncs->invokedefault)(npp, obj, args, argCount, result); -} - -bool NPN_Evaluate(NPP npp, NPObject *obj, NPString *script, NPVariant *result) -{ - NPN_Prolog(evaluate); - return FIND_FUNCTION_POINTER(NPN_EvaluateFP, qNetscapeFuncs->evaluate)(npp, obj, script, result); -} - -bool NPN_GetProperty(NPP npp, NPObject *obj, NPIdentifier propertyName, NPVariant *result) -{ - NPN_Prolog(getproperty); - return FIND_FUNCTION_POINTER(NPN_GetPropertyFP, qNetscapeFuncs->getproperty)(npp, obj, propertyName, result); -} - -bool NPN_SetProperty(NPP npp, NPObject *obj, NPIdentifier propertyName, const NPVariant *value) -{ - NPN_Prolog(setproperty); - return FIND_FUNCTION_POINTER(NPN_SetPropertyFP, qNetscapeFuncs->setproperty)(npp, obj, propertyName, value); -} - -bool NPN_RemoveProperty(NPP npp, NPObject *obj, NPIdentifier propertyName) -{ - NPN_Prolog(removeproperty); - return FIND_FUNCTION_POINTER(NPN_RemovePropertyFP, qNetscapeFuncs->removeproperty)(npp, obj, propertyName); -} - -bool NPN_HasProperty(NPP npp, NPObject *obj, NPIdentifier propertyName) -{ - NPN_Prolog(hasproperty); - return FIND_FUNCTION_POINTER(NPN_HasPropertyFP, qNetscapeFuncs->hasproperty)(npp, obj, propertyName); -} - -bool NPN_HasMethod(NPP npp, NPObject *obj, NPIdentifier methodName) -{ - NPN_Prolog(hasmethod); - return FIND_FUNCTION_POINTER(NPN_HasMethodFP, qNetscapeFuncs->hasmethod)(npp, obj, methodName); -} - -void NPN_ReleaseVariantValue(NPVariant *variant) -{ - NPN_Prolog(releasevariantvalue); - FIND_FUNCTION_POINTER(NPN_ReleaseVariantValueFP, qNetscapeFuncs->releasevariantvalue)(variant); -} - -void NPN_SetException(NPObject *obj, const char *message) -{ - qDebug("NPN_SetException: %s", message); - NPN_Prolog(setexception); - FIND_FUNCTION_POINTER(NPN_SetExceptionFP, qNetscapeFuncs->setexception)(obj, message); -} - -// Scripting implementation (JavaScript calling QObject) -#define NPClass_Prolog \ - if (!npobj->_class) return false; \ - if (!npobj->_class->qtnp) return false; \ - QtNPInstance *This = npobj->_class->qtnp; \ - if (!This->qt.object) return false; \ - QObject *qobject = This->qt.object \ - - -static NPObject *NPAllocate(NPP npp, NPClass *aClass) -{ - Q_UNUSED(npp); - Q_UNUSED(aClass); - - Q_ASSERT(false); - return 0; -} - -static void NPDeallocate(NPObject *npobj) -{ - Q_UNUSED(npobj); - - Q_ASSERT(false); - return; -} - -static void NPInvalidate(NPObject *npobj) -{ - if (npobj) - delete npobj->_class; - npobj->_class = 0; -} - -enum MetaOffset { MetaProperty, MetaMethod }; - -static int metaOffset(const QMetaObject *metaObject, MetaOffset offsetType) -{ - int classInfoIndex = metaObject->indexOfClassInfo("ToSuperClass"); - if (classInfoIndex == -1) - return 0; - QByteArray ToSuperClass = metaObject->classInfo(classInfoIndex).value(); - int offset = offsetType == MetaProperty ? metaObject->propertyOffset() - : metaObject->methodOffset(); - - while (ToSuperClass != metaObject->className()) { - metaObject = metaObject->superClass(); - if (!metaObject) - break; - offset -= offsetType == MetaProperty ? metaObject->propertyCount() - : metaObject->methodCount(); - } - return offset; -} - -static int publicMethodIndex(NPObject *npobj, const QByteArray &slotName, int argCount = -1) -{ - NPClass_Prolog; - const QMetaObject *metaObject = qobject->metaObject(); - for (int slotIndex = metaOffset(metaObject, MetaMethod); slotIndex < metaObject->methodCount(); ++slotIndex) { - const QMetaMethod slot = qobject->metaObject()->method(slotIndex); - if (slot.access() != QMetaMethod::Public || slot.methodType() == QMetaMethod::Signal) - continue; - QByteArray signature = slot.signature(); - if (signature.left(signature.indexOf('(')) == slotName) { - if (argCount == -1 || slot.parameterTypes().count() == argCount) - return slotIndex; - } - } - return -1; -} - -static bool NPClass_HasMethod(NPObject *npobj, NPIdentifier name) -{ - NPClass_Prolog; - Q_UNUSED(qobject); - return publicMethodIndex(npobj, NPN_UTF8FromIdentifier(name)) != -1; -} - -static bool NPClass_Invoke(NPObject *npobj, NPIdentifier name, const NPVariant *args, uint32 argCount, NPVariant *result) -{ - NPClass_Prolog; - const QByteArray slotName = NPN_UTF8FromIdentifier(name); - int slotIndex = publicMethodIndex(npobj, slotName, static_cast<int>(argCount)); - if (slotIndex == -1) { - NPN_SetException(npobj, QByteArray("No method '" + slotName + "' with " + QByteArray::number(argCount) + " parameters").constData()); - return false; - } - - const QMetaMethod slot = qobject->metaObject()->method(slotIndex); - QList<QByteArray> parameterTypes = slot.parameterTypes(); - if (parameterTypes.count() != static_cast<int>(argCount)) { - NPN_SetException(npobj, QByteArray("Wrong parameter count for method " + slotName).constData()); - return false; - } - - QVariant returnVariant(QVariant::nameToType(slot.typeName()), (void*)0); - QVector<QVariant> variants(parameterTypes.count()); // keep data alive - QVector<const void*> metacallArgs(parameterTypes.count() + 1); // arguments for qt_metacall - metacallArgs[0] = returnVariant.data(); // args[0] == return value - - for (int p = 0; p < parameterTypes.count(); ++p) { - QVariant::Type type = QVariant::nameToType(parameterTypes.at(p)); - if (type == QVariant::Invalid && parameterTypes.at(p) != "QVariant") { - NPN_SetException(npobj, QString("Parameter %1 in method '%2' has invalid type") - .arg(p).arg(QString::fromUtf8(slotName)).toAscii().constData()); - return false; - } - QVariant qvar = args[p]; - if (type != QVariant::Invalid && !qvar.convert(type)) { - NPN_SetException(npobj, QString("Parameter %1 to method '%2' needs to be convertible to '%3'") - .arg(p).arg(QString::fromUtf8(slotName)).arg(QString::fromAscii(parameterTypes.at(p))).toAscii().constData()); - return false; - } - - variants[p] = qvar; - if (type == QVariant::Invalid) - metacallArgs[p + 1] = &variants.at(p); - else - metacallArgs[p + 1] = variants.at(p).constData(); // must not detach! - } - - qobject->qt_metacall(QMetaObject::InvokeMetaMethod, slotIndex, const_cast<void**>(metacallArgs.data())); - if (returnVariant.isValid() && result) - *result = NPVariant::fromQVariant(This, returnVariant); - - return true; -} - -static bool NPClass_InvokeDefault(NPObject * /*npobj*/, const NPVariant * /*args*/, uint32 /*argCount*/, NPVariant * /*result*/) -{ - return false; -} - -static bool NPClass_HasProperty(NPObject *npobj, NPIdentifier name) -{ - NPClass_Prolog; - const QByteArray qname = NPN_UTF8FromIdentifier(name); - const QMetaObject *metaObject = qobject->metaObject(); - int propertyIndex = metaObject->indexOfProperty(qname); - if (propertyIndex == -1 || propertyIndex < metaOffset(metaObject, MetaProperty)) - return false; - QMetaProperty property = qobject->metaObject()->property(propertyIndex); - if (!property.isScriptable()) - return false; - - return true; -} - -static bool NPClass_GetProperty(NPObject *npobj, NPIdentifier name, NPVariant *result) -{ - NPClass_Prolog; - const QByteArray qname = NPN_UTF8FromIdentifier(name); - QVariant qvar = qobject->property(qname); - if (!qvar.isValid()) { - NPN_SetException(npobj, QByteArray("Failed to get value for property " + qname).constData()); - return false; - } - *result = NPVariant::fromQVariant(This, qvar); - return true; -} - -static bool NPClass_SetProperty(NPObject *npobj, NPIdentifier name, const NPVariant *result) -{ - NPClass_Prolog; - const QByteArray qname = NPN_UTF8FromIdentifier(name); - QVariant qvar = *result; - return qobject->setProperty(qname, qvar); -} - -static bool NPClass_RemoveProperty(NPObject * /*npobj*/, NPIdentifier /*name*/) -{ - return false; -} - -NPClass::NPClass(QtNPInstance *This) -{ - structVersion = NP_CLASS_STRUCT_VERSION; - allocate = 0; - deallocate = 0; - invalidate = NPInvalidate; - hasMethod = NPClass_HasMethod; - invoke = NPClass_Invoke; - invokeDefault = NPClass_InvokeDefault; - hasProperty = NPClass_HasProperty; - getProperty = NPClass_GetProperty; - setProperty = NPClass_SetProperty; - removeProperty = NPClass_RemoveProperty; - qtnp = This; - delete_qtnp = false; -} - -NPClass::~NPClass() -{ - if (delete_qtnp) - delete qtnp; -} - -// Type conversions -NPString NPString::fromQString(const QString &qstr) -{ - NPString npstring; - const QByteArray qutf8 = qstr.toUtf8(); - - npstring.utf8length = qutf8.length(); - npstring.utf8characters = (char*)NPN_MemAlloc(npstring.utf8length); - memcpy((char*)npstring.utf8characters, qutf8.constData(), npstring.utf8length); - - return npstring; -} - -NPString::operator QString() const -{ - return QString::fromUtf8(utf8characters, utf8length); -} - -NPVariant NPVariant::fromQVariant(QtNPInstance *This, const QVariant &qvariant) -{ - Q_ASSERT(This); - NPVariant npvar; - npvar.type = Null; - - QVariant qvar(qvariant); - switch(qvariant.type()) { - case QVariant::Bool: - npvar.value.boolValue = qvar.toBool(); - npvar.type = Boolean; - break; - case QVariant::Int: - npvar.value.intValue = qvar.toInt(); - npvar.type = Int32; - break; - case QVariant::Double: - npvar.value.doubleValue = qvar.toDouble(); - npvar.type = Double; - break; - case QVariant::UserType: - { - QByteArray userType = qvariant.typeName(); - if (userType.endsWith('*')) { - QtNPInstance *that = new QtNPInstance; - that->npp = This->npp; - that->qt.object = *(QObject**)qvariant.constData(); - NPClass *npclass = new NPClass(that); - npclass->delete_qtnp = true; - npvar.value.objectValue = NPN_CreateObject(This->npp, npclass); - npvar.type = Object; - } - } - break; - default: // including QVariant::String - if (!qvar.convert(QVariant::String)) - break; - npvar.type = String; - npvar.value.stringValue = NPString::fromQString(qvar.toString()); - break; - } - - return npvar; -} - -NPVariant::operator QVariant() const -{ - switch(type) { - case Void: - case Null: - return QVariant(); - case Object: - { - if (!value.objectValue || !value.objectValue->_class) - break; - NPClass *aClass = value.objectValue->_class; - // not one of ours? - if (aClass->invoke != NPClass_Invoke) - break; - // or just empty for some reason - QObject *qobject = aClass->qtnp->qt.object; - if (!qobject) - break; - QByteArray typeName = qobject->metaObject()->className(); - int userType = QMetaType::type(typeName + "*"); - if (userType == QVariant::Invalid) - break; - QVariant result(userType, &aClass->qtnp->qt.object); - // sanity check - Q_ASSERT(*(QObject**)result.constData() == aClass->qtnp->qt.object); - return result; - } - case Boolean: - return value.boolValue; - case Int32: - return value.intValue; - case Double: - return value.doubleValue; - case String: - return QString(value.stringValue); - default: - break; - } - return QVariant(); -} - -// Helper class for handling incoming data -class QtNPStream -{ -public: - QtNPStream(NPP instance, NPStream *st); - virtual ~QtNPStream() - { - } - - QString url() const; - bool finish(QtNPBindable *bindable); - - QByteArray buffer; - QFile file; - QString mime; - - NPError reason; - - NPP npp; - NPStream* stream; - -protected: - qint64 readData(char *, qint64); - qint64 writeData(const char *, qint64); -}; - -QtNPStream::QtNPStream(NPP instance, NPStream *st) - : reason(NPRES_DONE), npp(instance), stream(st) -{ -} - -/*! - Returns the URL from which the stream was created, or the empty string - for write-only streams. -*/ -QString QtNPStream::url() const -{ - if (!stream) - return QString(); - return QString::fromLocal8Bit(stream->url); -} - -class ErrorBuffer : public QBuffer -{ - friend class QtNPStream; -}; - -bool QtNPStream::finish(QtNPBindable *bindable) -{ - if (!bindable) - return false; - - bool res = false; - if (bindable) { - switch(reason) { - case NPRES_DONE: - // no data at all? url is probably local file (Opera) - if (buffer.isEmpty() && file.fileName().isEmpty()) { - QUrl u = QUrl::fromEncoded(stream->url); - QString lfn = u.toLocalFile(); - if (lfn.startsWith("//localhost/")) - lfn = lfn.mid(12); - file.setFileName(lfn); - } - - if (file.exists()) { - file.setObjectName(url()); - res = bindable->readData(&file, mime); - } else { - QBuffer io(&buffer); - io.setObjectName(url()); - res = bindable->readData(&io, mime); - } - break; - case NPRES_USER_BREAK: - { - ErrorBuffer empty; - empty.setObjectName(url()); - empty.setErrorString("User cancelled operation."), - res = bindable->readData(&empty, mime); - } - break; - case NPRES_NETWORK_ERR: - { - ErrorBuffer empty; - empty.setObjectName(url()); - empty.setErrorString("Network error during download."), - res = bindable->readData(&empty, mime); - } - break; - default: - break; - } - } - stream->pdata = 0; - delete this; - return res; -} - -// Helper class for forwarding signal emissions to the respective JavaScript -class QtSignalForwarder : public QObject -{ -public: - QtSignalForwarder(QtNPInstance *that) - : This(that), domNode(0) - { - } - - ~QtSignalForwarder() - { - if (domNode) - NPN_ReleaseObject(domNode); - } - - int qt_metacall(QMetaObject::Call call, int index, void **args); - -private: - QtNPInstance *This; - NPObject *domNode; -}; - -int QtSignalForwarder::qt_metacall(QMetaObject::Call call, int index, void **args) -{ - // no support for QObject method/properties etc! - if (!This || !This->npp || call != QMetaObject::InvokeMetaMethod - || !This->qt.object) - return index; - - switch (index) { - case -1: - { - QString msg = *(QString*)args[1]; - NPN_Status(This->npp, msg.toLocal8Bit().constData()); - } - break; - default: - { - QObject *qobject = This->qt.object; - if (!domNode) - NPN_GetValue(This->npp, NPNVPluginElementNPObject, &domNode); - if (!domNode) - break; - const QMetaObject *metaObject = qobject->metaObject(); - if (index < metaOffset(metaObject, MetaMethod)) - break; - - const QMetaMethod method = metaObject->method(index); - Q_ASSERT(method.methodType() == QMetaMethod::Signal); - - QByteArray signalSignature = method.signature(); - QByteArray scriptFunction = signalSignature.left(signalSignature.indexOf('(')); - NPIdentifier id = NPN_GetStringIdentifier(scriptFunction.constData()); - if (NPN_HasMethod(This->npp, domNode, id)) { - QList<QByteArray> parameterTypes = method.parameterTypes(); - QVector<NPVariant> parameters; - NPVariant result; - bool error = false; - for (int p = 0; p < parameterTypes.count(); ++p) { - QVariant::Type type = QVariant::nameToType(parameterTypes.at(p)); - if (type == QVariant::Invalid) { - NPN_SetException(domNode, QByteArray("Unsupported parameter type in ") + scriptFunction); - error = true; - break; - } - QVariant qvar(type, args[p + 1]); - NPVariant npvar = NPVariant::fromQVariant(This, qvar); - if (npvar.type == NPVariant::Null || npvar.type == NPVariant::Void) { - NPN_SetException(domNode, QByteArray("Unsupported parameter value in ") + scriptFunction); - error =true; - break; - } - parameters += npvar; - } - if (error) - break; - - NPError nperror = NPN_Invoke(This->npp, domNode, id, parameters.constData(), parameters.count(), &result); - if (nperror != NPERR_NO_ERROR && false) { // disabled, as NPN_Invoke seems to always return GENERICERROR - NPN_SetException(domNode, QByteArray("Error invoking event handler ") + scriptFunction); - } - // ### TODO: update return value (args[0]) (out-parameters not supported anyway) - NPN_ReleaseVariantValue(&result); - } - } - break; - } - - return index; -} - - -// Plugin functions -extern "C" NPError -NPP_GetValue(NPP instance, NPPVariable variable, void *value) -{ - if (!instance || !instance->pdata) - return NPERR_INVALID_INSTANCE_ERROR; - - QtNPInstance* This = (QtNPInstance*) instance->pdata; - - switch (variable) { - case NPPVpluginNameString: - { - static QByteArray name = qtNPFactory()->pluginName().toLocal8Bit(); - *(const char**)value = name.constData(); - } - break; - case NPPVpluginDescriptionString: - { - static QByteArray description = qtNPFactory()->pluginDescription().toLocal8Bit(); - *(const char**)value = description.constData(); - } - break; - -#ifdef Q_WS_X11 - case NPPVpluginNeedsXEmbed: - *(int*)value = true; // PRBool = int - break; -#endif - - case NPPVpluginScriptableNPObject: - { - NPObject *object = NPN_CreateObject(instance, new NPClass(This)); - *(NPObject**)value = object; - } - break; - case NPPVformValue: - { - QObject *object = This->qt.object; - const QMetaObject *metaObject = object->metaObject(); - int defaultIndex = metaObject->indexOfClassInfo("DefaultProperty"); - if (defaultIndex == -1) - return NPERR_GENERIC_ERROR; - QByteArray defaultProperty = metaObject->classInfo(defaultIndex).value(); - if (defaultProperty.isEmpty()) - return NPERR_GENERIC_ERROR; - QVariant defaultValue = object->property(defaultProperty); - if (!defaultValue.isValid()) - return NPERR_GENERIC_ERROR; - defaultProperty = defaultValue.toString().toUtf8(); - int size = defaultProperty.size(); - char *utf8 = (char*)NPN_MemAlloc(size + 1); - memcpy(utf8, defaultProperty.constData(), size); - utf8[size] = 0; // null-terminator - *(void**)value = utf8; - } - break; - default: - return NPERR_GENERIC_ERROR; - } - - return NPERR_NO_ERROR; -} - -extern "C" NPError -NPP_SetValue(NPP instance, NPPVariable variable, void *value) -{ - Q_UNUSED(variable); - Q_UNUSED(value); - - if (!instance || !instance->pdata) - return NPERR_INVALID_INSTANCE_ERROR; - - /* - switch(variable) { - default: - return NPERR_GENERIC_ERROR; - } - */ - return NPERR_NO_ERROR; -} - -extern "C" int16 NPP_Event(NPP instance, NPEvent* event) -{ - if (!instance || !instance->pdata) - return NPERR_INVALID_INSTANCE_ERROR; - - QtNPInstance* This = (QtNPInstance*) instance->pdata; - extern bool qtns_event(QtNPInstance *, NPEvent *); - return qtns_event(This, event) ? 1 : 0; -} - -#ifdef Q_WS_X11 -// Instance state information about the plugin. -extern "C" char* -NP_GetMIMEDescription(void) -{ - static QByteArray mime = qtNPFactory()->mimeTypes().join(";").toLocal8Bit(); - return (char*)mime.constData(); -} - -extern "C" NPError -NP_GetValue(void*, NPPVariable aVariable, void *aValue) -{ - NPError err = NPERR_NO_ERROR; - - static QByteArray name = qtNPFactory()->pluginName().toLocal8Bit(); - static QByteArray descr = qtNPFactory()->pluginDescription().toLocal8Bit(); - - switch (aVariable) { - case NPPVpluginNameString: - *static_cast<const char **> (aValue) = name.constData(); - break; - case NPPVpluginDescriptionString: - *static_cast<const char **>(aValue) = descr.constData(); - break; - case NPPVpluginNeedsXEmbed: - *static_cast<int*>(aValue) = true; - break; - case NPPVpluginTimerInterval: - case NPPVpluginKeepLibraryInMemory: - default: - err = NPERR_INVALID_PARAM; - break; - } - return err; -} -#endif - -/* -** NPP_New is called when your plugin is instantiated (i.e. when an EMBED -** tag appears on a page). -*/ -extern "C" NPError -NPP_New(NPMIMEType pluginType, - NPP instance, - uint16 mode, - int16 argc, - char* argn[], - char* argv[], - NPSavedData* /*saved*/) -{ - if (!instance) - return NPERR_INVALID_INSTANCE_ERROR; - - QtNPInstance* This = new QtNPInstance; - if (!This) - return NPERR_OUT_OF_MEMORY_ERROR; - - instance->pdata = This; - This->filter = 0; - This->bindable = 0; - This->npp = instance; - This->fMode = mode; // NP_EMBED, NP_FULL, or NP_BACKGROUND (see npapi.h) - This->window = 0; - This->qt.object = 0; -#ifdef Q_WS_MAC - This->rootWidget = 0; -#endif - This->pendingStream = 0; // stream might be created before instance - This->mimetype = QString::fromLatin1(pluginType); - This->notificationSeqNum = 0; - - for (int i = 0; i < argc; i++) { - QByteArray name = QByteArray(argn[i]).toLower(); - if (name == "id") - This->htmlID = argv[i]; - This->parameters[name] = QVariant(argv[i]); - } - - return NPERR_NO_ERROR; -} - -extern "C" NPError -NPP_Destroy(NPP instance, NPSavedData** /*save*/) -{ - if (!instance || !instance->pdata) - return NPERR_INVALID_INSTANCE_ERROR; - - QtNPInstance* This = (QtNPInstance*) instance->pdata; - -#ifdef Q_WS_X11 - //This->widget->destroy(false, false); // X has destroyed all windows -#endif - delete This->qt.object; - This->qt.object = 0; - delete This->filter; - This->filter = 0; - extern void qtns_destroy(QtNPInstance *This); - qtns_destroy(This); - delete This; - instance->pdata = 0; - - return NPERR_NO_ERROR; -} - -static QtNPInstance *next_pi = 0; // helper to connect to QtNPBindable - -extern "C" NPError -NPP_SetWindow(NPP instance, NPWindow* window) -{ - if (!instance) - return NPERR_INVALID_INSTANCE_ERROR; - - QtNPInstance* This = (QtNPInstance*) instance->pdata; - extern void qtns_setGeometry(QtNPInstance*, const QRect &, const QRect &); - - const QRect clipRect(window->clipRect.left, window->clipRect.top, - window->clipRect.right - window->clipRect.left, - window->clipRect.bottom - window->clipRect.top); - if (window) - This->geometry = QRect(window->x, window->y, window->width, window->height); - - // take a shortcut if all that was changed is the geometry - if (qobject_cast<QWidget*>(This->qt.object) && window && This->window == (QtNPInstance::Widget)window->window) { - qtns_setGeometry(This, This->geometry, clipRect); - return NPERR_NO_ERROR; - } - - delete This->qt.object; - This->qt.object = 0; - extern void qtns_destroy(QtNPInstance *This); - qtns_destroy(This); - - if (!window) { - This->window = 0; - return NPERR_NO_ERROR; - } - - This->window = (QtNPInstance::Widget)window->window; -#ifdef Q_WS_X11 - //This->display = ((NPSetWindowCallbackStruct *)window->ws_info)->display; -#endif - - extern void qtns_initialize(QtNPInstance*); - qtns_initialize(This); - - next_pi = This; - This->qt.object = qtNPFactory()->createObject(This->mimetype); - next_pi = 0; - - if (!This->qt.object) - return NPERR_NO_ERROR; - - if (!This->htmlID.isEmpty()) - This->qt.object->setObjectName(QLatin1String(This->htmlID)); - - This->filter = new QtSignalForwarder(This); - QStatusBar *statusbar = qFindChild<QStatusBar*>(This->qt.object); - if (statusbar) { - int statusSignal = statusbar->metaObject()->indexOfSignal("messageChanged(QString)"); - if (statusSignal != -1) { - QMetaObject::connect(statusbar, statusSignal, This->filter, -1); - statusbar->hide(); - } - } - - const QMetaObject *mo = This->qt.object->metaObject(); - for (int p = 0; p < mo->propertyCount(); ++p) { - const QMetaProperty property = mo->property(p); - QByteArray name(property.name()); - QVariant value = This->parameters.value(name.toLower()); - if (value.isValid()) - property.write(This->qt.object, value); - } - for (int methodIndex = 0; methodIndex < mo->methodCount(); ++methodIndex) { - const QMetaMethod method = mo->method(methodIndex); - if (method.methodType() == QMetaMethod::Signal) - QMetaObject::connect(This->qt.object, methodIndex, This->filter, methodIndex); - } - - if (This->pendingStream) { - This->pendingStream->finish(This->bindable); - This->pendingStream = 0; - } - - if (!qobject_cast<QWidget*>(This->qt.object)) - return NPERR_NO_ERROR; - - extern void qtns_embed(QtNPInstance*); - qtns_embed(This); - - QEvent e(QEvent::EmbeddingControl); - QApplication::sendEvent(This->qt.widget, &e); - - if (!This->qt.widget->testAttribute(Qt::WA_PaintOnScreen)) - This->qt.widget->setAutoFillBackground(true); - This->qt.widget->raise(); - qtns_setGeometry(This, This->geometry, clipRect); - This->qt.widget->show(); - - return NPERR_NO_ERROR; -} - -extern "C" NPError -NPP_NewStream(NPP instance, - NPMIMEType type, - NPStream *stream, - NPBool /*seekable*/, - uint16 *stype) -{ - if (!instance) - return NPERR_INVALID_INSTANCE_ERROR; - - QtNPInstance* This = (QtNPInstance*) instance->pdata; - if (!This) - return NPERR_NO_ERROR; - - QtNPStream *qstream = new QtNPStream(instance, stream); - qstream->mime = QString::fromLocal8Bit(type); - stream->pdata = qstream; - - // Workaround bug in Firefox/Gecko/Mozilla; observed in version 3.0.5 on Windows: - // On page reload, it does not call StreamAsFile() even when stype is AsFileOnly - if (QByteArray(NPN_UserAgent(instance)).contains("Mozilla")) - *stype = NP_NORMAL; - else - *stype = NP_ASFILEONLY; - - return NPERR_NO_ERROR; -} - -extern "C" int32 -NPP_WriteReady(NPP, NPStream *stream) -{ - if (stream->pdata) - return 0x0FFFFFFF; - return 0; -} - -// Both Netscape and FireFox call this for OnDemand streams as well... -extern "C" int32 -NPP_Write(NPP instance, NPStream *stream, int32 /*offset*/, int32 len, void *buffer) -{ - if (!instance || !stream || !stream->pdata) - return NPERR_INVALID_INSTANCE_ERROR; - - // this should not be called, as we always demand a download - QtNPStream *qstream = (QtNPStream*)stream->pdata; - QByteArray data((const char*)buffer, len); // make deep copy - qstream->buffer += data; - - return len; -} - -// Opera calls this for OnDemand streams without calling NPP_Write first -extern "C" NPError -NPP_DestroyStream(NPP instance, NPStream *stream, NPError reason) -{ - if (!instance || !instance->pdata || !stream || !stream->pdata) - return NPERR_INVALID_INSTANCE_ERROR; - - QtNPInstance *This = (QtNPInstance*)instance->pdata; - QtNPStream *qstream = (QtNPStream*)stream->pdata; - qstream->reason = reason; - - if (!This->qt.object) { // not yet initialized - This->pendingStream = qstream; - return NPERR_NO_ERROR; - } - - This->pendingStream = 0; - qstream->finish(This->bindable); - - return NPERR_NO_ERROR; -} - -extern "C" void -NPP_StreamAsFile(NPP instance, NPStream *stream, const char* fname) -{ - if (!instance || !stream || !stream->pdata) - return; - - QString path = QString::fromLocal8Bit(fname); -#ifdef Q_WS_MAC - path = "/" + path.section(':', 1).replace(':', '/'); -#endif - - QtNPStream *qstream = (QtNPStream*)stream->pdata; - qstream->file.setFileName(path); -} - -extern "C" void -NPP_URLNotify(NPP instance, - const char* url, - NPReason reason, - void* notifyData) -{ - if (!instance) - return; - QtNPInstance* This = (QtNPInstance*) instance->pdata; - if (!This->bindable) - return; - - QtNPBindable::Reason r; - switch (reason) { - case NPRES_DONE: - r = QtNPBindable::ReasonDone; - break; - case NPRES_USER_BREAK: - r = QtNPBindable::ReasonBreak; - break; - case NPRES_NETWORK_ERR: - r = QtNPBindable::ReasonError; - break; - default: - r = QtNPBindable::ReasonUnknown; - break; - } - - qint32 id = static_cast<qint32>(reinterpret_cast<size_t>(notifyData)); - if (id < 0) // Sanity check - id = 0; - - This->bindable->transferComplete(QString::fromLocal8Bit(url), id, r); -} - -extern "C" void -NPP_Print(NPP instance, NPPrint* printInfo) -{ - if(!printInfo || !instance) - return; - - QtNPInstance* This = (QtNPInstance*) instance->pdata; - if (!This->bindable) - return; - -/* - if (printInfo->mode == NP_FULL) { - printInfo->print.fullPrint.pluginPrinted = This->bindable->printFullPage(); - } else if (printInfo->mode == NP_EMBED) { - extern void qtns_print(QtNPInstance*, NPPrint*); - qtns_print(This, printInfo); - } -*/ -} - -// Plug-in entrypoints - these are called by the browser - -// Fills in functiontable used by browser to call entry points in plugin. -extern "C" NPError WINAPI NP_GetEntryPoints(NPPluginFuncs* pFuncs) -{ - if(!pFuncs) - return NPERR_INVALID_FUNCTABLE_ERROR; - if(!pFuncs->size) - pFuncs->size = sizeof(NPPluginFuncs); - else if (pFuncs->size < sizeof(NPPluginFuncs)) - return NPERR_INVALID_FUNCTABLE_ERROR; - - pFuncs->version = (NP_VERSION_MAJOR << 8) | NP_VERSION_MINOR; - pFuncs->newp = MAKE_FUNCTION_POINTER(NPP_New); - pFuncs->destroy = MAKE_FUNCTION_POINTER(NPP_Destroy); - pFuncs->setwindow = MAKE_FUNCTION_POINTER(NPP_SetWindow); - pFuncs->newstream = MAKE_FUNCTION_POINTER(NPP_NewStream); - pFuncs->destroystream = MAKE_FUNCTION_POINTER(NPP_DestroyStream); - pFuncs->asfile = MAKE_FUNCTION_POINTER(NPP_StreamAsFile); - pFuncs->writeready = MAKE_FUNCTION_POINTER(NPP_WriteReady); - pFuncs->write = MAKE_FUNCTION_POINTER(NPP_Write); - pFuncs->print = MAKE_FUNCTION_POINTER(NPP_Print); - pFuncs->event = MAKE_FUNCTION_POINTER(NPP_Event); - pFuncs->urlnotify = MAKE_FUNCTION_POINTER(NPP_URLNotify); - pFuncs->javaClass = 0; - pFuncs->getvalue = MAKE_FUNCTION_POINTER(NPP_GetValue); - pFuncs->setvalue = MAKE_FUNCTION_POINTER(NPP_SetValue); - return NPERR_NO_ERROR; -} - -enum NPNToolkitType -{ - NPNVGtk12 = 1, - NPNVGtk2 -}; - -#ifndef Q_WS_X11 -extern "C" NPError WINAPI NP_Initialize(NPNetscapeFuncs* pFuncs) -{ - if(!pFuncs) - return NPERR_INVALID_FUNCTABLE_ERROR; - - qNetscapeFuncs = pFuncs; - int navMajorVers = qNetscapeFuncs->version >> 8; - - // if the plugin's major version is lower than the Navigator's, - // then they are incompatible, and should return an error - if(navMajorVers > NP_VERSION_MAJOR) - return NPERR_INCOMPATIBLE_VERSION_ERROR; - - return NPERR_NO_ERROR; -} -#else -extern "C" NPError WINAPI NP_Initialize(NPNetscapeFuncs* nFuncs, NPPluginFuncs* pFuncs) -{ - if(!nFuncs) - return NPERR_INVALID_FUNCTABLE_ERROR; - - qNetscapeFuncs = nFuncs; - int navMajorVers = qNetscapeFuncs->version >> 8; - - // if the plugin's major version is lower than the Navigator's, - // then they are incompatible, and should return an error - if(navMajorVers > NP_VERSION_MAJOR) - return NPERR_INCOMPATIBLE_VERSION_ERROR; - - // check if the Browser supports the XEmbed protocol - int supportsXEmbed = 0; - NPError err = NPN_GetValue(0, NPNVSupportsXEmbedBool, (void *)&supportsXEmbed); - if (err != NPERR_NO_ERROR ||!supportsXEmbed) - return NPERR_INCOMPATIBLE_VERSION_ERROR; - - return NP_GetEntryPoints(pFuncs); -} -#endif - -extern "C" NPError WINAPI NP_Shutdown() -{ - delete qNP; - qNP = 0; - - extern void qtns_shutdown(); - qtns_shutdown(); - - qNetscapeFuncs = 0; - return NPERR_NO_ERROR; -} - - -/*! - \class QtNPBindable qtnetscape.h - \brief The QtNPBindable class provides an interface between a widget and the web browser. - - Inherit your plugin widget class from both QWidget (or QObject) and QtNPBindable - to be able to call the functions of this class, and to reimplement the virtual - functions. The \l{moc}{meta-object compiler} requires you to inherit from the - QObject subclass first. - - \code - class PluginWidget : public QWidget, public QtNPBindable - { - Q_OBJECT - public: - PluginWidget(QWidget *parent = 0) - { - } - - //... - }; - \endcode -*/ - -/*! - \enum QtNPBindable::DisplayMode - - \brief This enum specifies the different display modes of a plugin - - \value Embedded The plugin widget is embedded in a web page, usually - with the <EMBED> or the <OBJECT> tag. - \value Fullpage The plugin widget is the primary content of the web browser, which - is usually the case when the web browser displays a file the plugin supports. -*/ - -/*! - \enum QtNPBindable::Reason - - \brief This enum specifies how an URL operation was completed - - \value ReasonDone - \value ReasonBreak - \value ReasonError - \value ReasonUnknown -*/ - -/*! - Constructs a QtNPBindable object. - - This can only happen when the plugin object is created. -*/ -QtNPBindable::QtNPBindable() -: pi(next_pi) -{ - if (pi) - pi->bindable = this; - next_pi = 0; -} - -/*! - Destroys the object. - - This can only happen when the plugin object is destroyed. -*/ -QtNPBindable::~QtNPBindable() -{ -} - -/*! - Returns the parameters passed to the plugin instance. - - The framework sets the properties of the plugin to the corresponding - parameters when the plugin object has been created, but you can - use this function to process additional parameters. - - Note that the SGML specification does not permit multiple - arguments with the same name. -*/ -QMap<QByteArray, QVariant> QtNPBindable::parameters() const -{ - if (!pi) - return QMap<QByteArray, QVariant>(); - return pi->parameters; -} - -/*! - Returns the user agent (browser name) containing this plugin. - - This is a wrapper around NPN_UserAgent. - - \sa getBrowserVersion() -*/ -QString QtNPBindable::userAgent() const -{ - if (!pi) - return QString(); - return QString::fromLocal8Bit(NPN_UserAgent(pi->npp)); -} - -/*! - Extracts the version of the plugin API used by this plugin into \a major - and \a minor. - - See http://devedge-temp.mozilla.org/library/manuals/2002/plugin/1.0/ - for an explanation of those values. - - \sa getBrowserVersion() userAgent() -*/ -void QtNPBindable::getNppVersion(int *major, int *minor) const -{ - int dummy = 0; - if (pi) - NPN_Version(major, minor, &dummy, &dummy); -} - -/*! - Extracts the version of the browser into \a major and \a minor. - - See http://devedge-temp.mozilla.org/library/manuals/2002/plugin/1.0/ - for an explanation of those values. - - \sa getNppVersion() userAgent() -*/ -void QtNPBindable::getBrowserVersion(int *major, int *minor) const -{ - int dummy = 0; - if (pi) - NPN_Version(&dummy, &dummy, major, minor); -} - -/*! - Returns the display mode of the plugin. -*/ -QtNPBindable::DisplayMode QtNPBindable::displayMode() const -{ - if (!pi) - return Embedded; - return (QtNPBindable::DisplayMode)pi->fMode; -} - -/*! - Returns the mime type this plugin has been instantiated for. -*/ -QString QtNPBindable::mimeType() const -{ - if (!pi) - return QString(); - return pi->mimetype; -} - -/*! - Returns the browser's plugin instance associated with this plugin object. - The instance is required to call functions in the Netscape Plugin API, - i.e. NPN_GetJavaPeer(). - - The instance returned is only valid as long as this object is. - - See http://devedge-temp.mozilla.org/library/manuals/2002/plugin/1.0/ - for documentation of the \c NPP type. -*/ -NPP QtNPBindable::instance() const -{ - if (!pi) - return 0; - return pi->npp; -} - -/*! - Reimplement this function to read data from \a source provided with - mime type \a format. The data is the one specified in the \c src or - \c data attribute of the \c{<EMBED>} or \c{<OBJECT>} tag of in - HTML page. This function is called once for every stream the browser - creates for the plugin. - - Return true to indicate successfull processing of the data, otherwise - return false. The default implementation does nothing and returns false. -*/ - -bool QtNPBindable::readData(QIODevice *source, const QString &format) -{ - Q_UNUSED(source); - Q_UNUSED(format); - return false; -} - -/*! - Requests that the \a url be retrieved and sent to the named \a window (or - a new window if \a window is empty), and returns the ID of the request that is - delivered to transferComplete() when the get-operation has finished. Returns 0 when - the browser or the system doesn't support notification, or -1 when an error occured. - - \code - void MyPlugin::aboutQtSoftware() - { - openUrl("http://qt.nokia.com"); - } - \endcode - - See Netscape's JavaScript documentation for an explanation of window names. - - \sa transferComplete() uploadData() uploadFile() -*/ -int QtNPBindable::openUrl(const QString &url, const QString &window) -{ - if (!pi) - return -1; - QString wnd = window; - if (wnd.isEmpty()) - wnd = "_blank"; - - qint32 id = pi->getNotificationSeqNum(); - NPError err = NPN_GetURLNotify(pi->npp, url.toLocal8Bit().constData(), wnd.toLocal8Bit().constData(), reinterpret_cast<void*>(id)); - if (err != NPERR_NO_ERROR) - id = -1; - - if (err == NPERR_INCOMPATIBLE_VERSION_ERROR) { - err = NPN_GetURL(pi->npp, url.toLocal8Bit().constData(), wnd.toLocal8Bit().constData()); - if (NPERR_NO_ERROR == err) - id = 0; - else - id = -1; - } - return id; -} - -/*! - Posts \a data to \a url, and displays the result in \a window. Returns the ID of the request - that is delivered to transferComplete() when the post-operation has finished. Returns 0 when - the browser or the system doesn't support notification, or -1 when an error occured. - - \code - void MyPlugin::sendMail() - { - uploadData("mailto:fred@somewhere.com", QString(), "There is a new file for you!"); - } - \endcode - - See Netscape's JavaScript documentation for an explanation of window names. - - \sa transferComplete() openUrl() uploadFile() -*/ -int QtNPBindable::uploadData(const QString &url, const QString &window, const QByteArray &data) -{ - if (!pi) - return -1; - - int id = pi->getNotificationSeqNum(); - if (NPERR_NO_ERROR != NPN_PostURLNotify(pi->npp, url.toLocal8Bit().constData(), window.isEmpty() ? 0 : window.toLocal8Bit().constData(), data.size(), data.constData(), false, reinterpret_cast<void*>(id))) - id = -1; - - return id; -} - -/*! - Posts \a filename to \a url, and displays the result in \a window. Returns the ID of - the request that is delivered to transferComplete() when the post-operation has finished. - Returns 0 when the browser or the system doesn't support notification, or -1 when an - error occured. - - \code - void MyPlugin::uploadFile() - { - uploadFile("ftp://ftp.somewhere.com/incoming", "response", "c:\\temp\\file.txt"); - } - \endcode - - See Netscape's JavaScript documentation for an explanation of window names. - - \sa transferComplete() uploadData() openUrl() -*/ - -int QtNPBindable::uploadFile(const QString &url, const QString &window, const QString &filename) -{ - if (!pi) - return -1; - - QByteArray data = filename.toLocal8Bit(); - int id = pi->getNotificationSeqNum(); - if (NPERR_NO_ERROR != NPN_PostURLNotify(pi->npp, url.toLocal8Bit().constData(), window.isEmpty() ? 0 : window.toLocal8Bit().constData(), data.size(), data.constData(), true, reinterpret_cast<void*>(id))) - id = -1; - - return id; -} - -/*! - Called as a result of a call to openUrl, uploadData or uploadFile. - \a url corresponds to the respective parameter, and \a id to value returned - by the call. \a reason indicates how the transfer was completed. -*/ -void QtNPBindable::transferComplete(const QString &url, int id, Reason reason) -{ - Q_UNUSED(url) - Q_UNUSED(id) - Q_UNUSED(reason) -} - - -/****************************************************************************** - * The plugin itself - only one ever exists, created by QtNPFactory::create() - *****************************************************************************/ - - -/*! - \class QtNPFactory qtbrowserplugin.h - \brief The QtNPFactory class provides the factory for plugin objects. - - Implement this factory once in your plugin project to provide information - about the plugin and to create the plugin objects. Subclass QtNPFactory and - implement the pure virtual functions, and export the factory using the - \c QTNPFACTORY_EXPORT() macro. - - If you use the Q_CLASSINFO macro in your object classes you can use the - \c QTNPFACTORY_BEGIN(), \c QTNPCLASS() and \c QTNPFACTORY_END() macros to - generate a factory implementation: - - \code - class Widget : public QWidget - { - Q_OBJECT - Q_CLASSINFO("MIME", "application/x-graphable:g1n:Graphable data") - public: - ... - }; - - QTNPFACTORY_BEGIN("Plugin name", "Plugin description") - QTNPCLASS(WidgetClass) - QTNPFACTORY_END() - \endcode - - The classes exposed must provide a constructor. - - If Qt is linked to the plugin as a dynamic library, only one instance of - QApplication will exist \e{across all plugins that have been made with Qt}. - So, your plugin should tread lightly on global settings. Do not, for example, - use QApplication::setFont() - that will change the font in every widget of - every Qt-based plugin currently loaded! -*/ - -/*! - Creates a QtNPFactory. -*/ -QtNPFactory::QtNPFactory() -{ -} - -/*! - Destroys the QtNPFactory. - - This is called by the plugin binding code just before the plugin is - about to be unloaded from memory. If createObject() has been called, - a QApplication will still exist at this time, but will be deleted - shortly after, just before the plugin is deleted. -*/ -QtNPFactory::~QtNPFactory() -{ -} - - -/*! - \fn QStringList QtNPFactory::mimeTypes() const - - Reimplement this function to return the MIME types of the data formats - supported by your plugin. The format of each string is - mime:extension(s):description: - - \code - QStringList mimeTypes() const - { - QStringList list; - list << "image/x-png:png:PNG Image" - << "image/png:png:PNG Image" - << "image/jpeg:jpg,jpeg:JPEG Image"; - return list; - } - \endcode -*/ - -/*! - \fn QObject *QtNPFactory::createObject(const QString &type) - - Reimplement this function to return the QObject or QWidget subclass - supporting the mime type \a type, or 0 if the factory doesn't support - the type requested. - - \a type will be in the same form as the leftmost (mime) part of - the string(s) returned by mimeTypes(), e.g. "image/png". -*/ - -/*! - \fn QString QtNPFactory::pluginName() const - - Reimplement this function to return the name of the plugin. -*/ - -/*! - \fn QString QtNPFactory::pluginDescription() const - - Reimplement this function to return the description of the plugin. -*/ diff --git a/x2gobrowserplugin-2.4_1/src/qtbrowserplugin.def b/x2gobrowserplugin-2.4_1/src/qtbrowserplugin.def deleted file mode 100644 index ce7f119..0000000 --- a/x2gobrowserplugin-2.4_1/src/qtbrowserplugin.def +++ /dev/null @@ -1,4 +0,0 @@ -EXPORTS - NP_GetEntryPoints @1 - NP_Initialize @2 - NP_Shutdown @3 diff --git a/x2gobrowserplugin-2.4_1/src/qtbrowserplugin.h b/x2gobrowserplugin-2.4_1/src/qtbrowserplugin.h deleted file mode 100644 index 6b87bfb..0000000 --- a/x2gobrowserplugin-2.4_1/src/qtbrowserplugin.h +++ /dev/null @@ -1,176 +0,0 @@ -/**************************************************************************** -** -** Copyright (C) 2009 Nokia Corporation and/or its subsidiary(-ies). -** All rights reserved. -** Contact: Nokia Corporation (qt-info@nokia.com) -** -** This file is part of a Qt Solutions component. -** -** You may use this file under the terms of the BSD license as follows: -** -** "Redistribution and use in source and binary forms, with or without -** modification, are permitted provided that the following conditions are -** met: -** * Redistributions of source code must retain the above copyright -** notice, this list of conditions and the following disclaimer. -** * Redistributions in binary form must reproduce the above copyright -** notice, this list of conditions and the following disclaimer in -** the documentation and/or other materials provided with the -** distribution. -** * Neither the name of Nokia Corporation and its Subsidiary(-ies) nor -** the names of its contributors may be used to endorse or promote -** products derived from this software without specific prior written -** permission. -** -** THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS -** "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT -** LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR -** A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT -** OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, -** SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT -** LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, -** DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY -** THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT -** (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE -** OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE." -** -****************************************************************************/ - -#ifndef QTNETSCAPE_H -#define QTNETSCAPE_H - -#include <QtCore/QMetaObject> -#include <QtCore/QFile> -#include <QtCore/QDateTime> -#include <QtGui/QPainter> - - -struct QtNPInstance; -class QtNPBindable; -class QtNPStreamPrivate; - -struct NPP_t; -typedef NPP_t* NPP; - -class QtNPBindable -{ - friend class QtNPStream; -public: - enum Reason { - ReasonDone = 0, - ReasonBreak = 1, - ReasonError = 2, - ReasonUnknown = -1 - }; - enum DisplayMode - { - Embedded = 1, - Fullpage = 2 - }; - - QMap<QByteArray, QVariant> parameters() const; - DisplayMode displayMode() const; - QString mimeType() const; - - QString userAgent() const; - void getNppVersion(int *major, int *minor) const; - void getBrowserVersion(int *major, int *minor) const; - - // incoming streams (SRC=... tag) - virtual bool readData(QIODevice *source, const QString &format); - - // URL stuff - int openUrl(const QString &url, const QString &window = QString()); - int uploadData(const QString &url, const QString &window, const QByteArray &data); - int uploadFile(const QString &url, const QString &window, const QString &filename); - virtual void transferComplete(const QString &url, int id, Reason r); - - NPP instance() const; - -protected: - QtNPBindable(); - virtual ~QtNPBindable(); - -private: - QtNPInstance* pi; -}; - -class QtNPFactory { -public: - QtNPFactory(); - virtual ~QtNPFactory(); - - virtual QStringList mimeTypes() const = 0; - virtual QObject* createObject(const QString &type) = 0; - - virtual QString pluginName() const = 0; - virtual QString pluginDescription() const = 0; -}; - -extern QtNPFactory *qtNPFactory(); - -template<class T> -class QtNPClass : public QtNPFactory -{ -public: - QtNPClass() {} - - QObject *createObject(const QString &key) - { - foreach (QString mime, mimeTypes()) { - if (mime.left(mime.indexOf(':')) == key) - return new T; - } - return 0; - } - - QStringList mimeTypes() const - { - const QMetaObject &mo = T::staticMetaObject; - return QString::fromLatin1(mo.classInfo(mo.indexOfClassInfo("MIME")).value()).split(';'); - } - - QString pluginName() const { return QString(); } - QString pluginDescription() const { return QString(); } -}; - -#define QTNPFACTORY_BEGIN(Name, Description) \ -class QtNPClassList : public QtNPFactory \ -{ \ - QHash<QString, QtNPFactory*> factories; \ - QStringList mimeStrings; \ - QString m_name, m_description; \ -public: \ - QtNPClassList() \ - : m_name(Name), m_description(Description) \ - { \ - QtNPFactory *factory = 0; \ - QStringList keys; \ - -#define QTNPCLASS(Class) \ - { \ - factory = new QtNPClass<Class>; \ - keys = factory->mimeTypes(); \ - foreach (QString key, keys) { \ - mimeStrings.append(key); \ - factories.insert(key.left(key.indexOf(':')), factory); \ - } \ - } \ - -#define QTNPFACTORY_END() \ - } \ - ~QtNPClassList() { /*crashes? qDeleteAll(factories);*/ } \ - QObject *createObject(const QString &mime) { \ - QtNPFactory *factory = factories.value(mime); \ - return factory ? factory->createObject(mime) : 0; \ - } \ - QStringList mimeTypes() const { return mimeStrings; } \ - QString pluginName() const { return m_name; } \ - QString pluginDescription() const { return m_description; } \ -}; \ -QtNPFactory *qtns_instantiate() { return new QtNPClassList; } \ - -#define QTNPFACTORY_EXPORT(Class) \ -QtNPFactory *qtns_instantiate() { return new Class; } - -#endif // QTNETSCAPE_H diff --git a/x2gobrowserplugin-2.4_1/src/qtbrowserplugin.pri b/x2gobrowserplugin-2.4_1/src/qtbrowserplugin.pri deleted file mode 100644 index 6b5f08d..0000000 --- a/x2gobrowserplugin-2.4_1/src/qtbrowserplugin.pri +++ /dev/null @@ -1,74 +0,0 @@ -TEMPLATE = lib -CONFIG += dll -win32-* { - # Uncomment the following line to build a plugin that can be used also in - # Internet Explorer, through ActiveX. - # CONFIG += qaxserver -} else { - CONFIG += plugin -} - -INCLUDEPATH += $$PWD -DEPENDPATH += $$PWD - -SOURCES += $$PWD/qtbrowserplugin.cpp -HEADERS += $$PWD/qtbrowserplugin.h qtnpapi.h - -win32-* { - SOURCES += $$PWD/qtbrowserplugin_win.cpp - !isEmpty(TARGET) { - TARGET = np$$TARGET - } - LIBS += -luser32 - - qaxserver { - DEF_FILE += $$PWD/qtbrowserpluginax.def - } else { - DEF_FILE += $$PWD/qtbrowserplugin.def - } - - firefox { - exists("c:/program files/mozilla firefox/plugins") { - DLLDESTDIR += "c:/program files/mozilla firefox/plugins" - } else { - message("Firefox not found at default location") - } - } - opera { - exists("c:/program files/opera/program/plugins") { - DLLDESTDIR += "c:/program files/opera/program/plugins" - } else { - message("Opera not found at default location") - } - } - netscape { - exists("c:/program files/netscape/netscape browser/plugins") { - DLLDESTDIR += "c:/program files/netscape/netscape browser/plugins" - } else { - message("Netscape not found at default location") - } - } -} else:mac { - CONFIG += plugin_bundle - SOURCES += $$PWD/qtbrowserplugin_mac.cpp - #target.path = /Library/Internet\ Plugins - #INSTALLS += target -} else { - SOURCES += $$PWD/qtbrowserplugin_x11.cpp - INCLUDEPATH += /usr/include/X11 - - # Avoiding symbol clash with other instances of the Qt library - # (ref. developingplugins.html in the doc.): - # - # For Qt 4.4 and later, just configure Qt to use a separate namespace: - # configure -qtnamespace SomeNamespace - # - # For Qt 4.3: Uncomment the line below. - # It makes the dynamic linker prefer our own Qt symbols for the plugin, - # provided that our Qt is statically built and linked into the - # plugin. Note that to force the linker to prefer the static Qt - # libraries (.a files), the dynamic libraries (.so) files must not - # be present in the lib directory. - # - # QMAKE_LFLAGS += -Wl,-Bsymbolic -} diff --git a/x2gobrowserplugin-2.4_1/src/qtbrowserplugin_mac.cpp b/x2gobrowserplugin-2.4_1/src/qtbrowserplugin_mac.cpp deleted file mode 100644 index c757bda..0000000 --- a/x2gobrowserplugin-2.4_1/src/qtbrowserplugin_mac.cpp +++ /dev/null @@ -1,560 +0,0 @@ -/**************************************************************************** -** -** Copyright (C) 2009 Nokia Corporation and/or its subsidiary(-ies). -** All rights reserved. -** Contact: Nokia Corporation (qt-info@nokia.com) -** -** This file is part of a Qt Solutions component. -** -** You may use this file under the terms of the BSD license as follows: -** -** "Redistribution and use in source and binary forms, with or without -** modification, are permitted provided that the following conditions are -** met: -** * Redistributions of source code must retain the above copyright -** notice, this list of conditions and the following disclaimer. -** * Redistributions in binary form must reproduce the above copyright -** notice, this list of conditions and the following disclaimer in -** the documentation and/or other materials provided with the -** distribution. -** * Neither the name of Nokia Corporation and its Subsidiary(-ies) nor -** the names of its contributors may be used to endorse or promote -** products derived from this software without specific prior written -** permission. -** -** THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS -** "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT -** LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR -** A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT -** OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, -** SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT -** LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, -** DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY -** THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT -** (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE -** OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE." -** -****************************************************************************/ - -#include <QtGui/QApplication> -#include <QtCore/QStringList> -#include <QtCore/QPointer> -#include <QtGui/QWidget> -#include <QtCore/QEvent> -#include <QtCore/QDebug> -#include <QtCore/QRect> -#include <QtGui/QMouseEvent> -#include <QtGui/QHoverEvent> -#include <QtGui/QKeyEvent> - -#include <Carbon/Carbon.h> - -#include "qtnpapi.h" - -#include "qtbrowserplugin.h" -#include "qtbrowserplugin_p.h" - -static bool ownsqapp = false; -extern void qt_mac_set_native_menubar(bool b); -const UInt32 kWidgetCreatorQt = 'cute'; -enum { - kWidgetPropertyQWidget = 'QWId' //QWidget * -}; - -class -QMacBrowserRoot : public QWidget -{ - Q_OBJECT -public: - QMacBrowserRoot(HIViewRef root) : QWidget() - { - // make sure we're not registered with Qt before create - WindowRef window = HIViewGetWindow(root); - QWidget *oldwindow=0; - OSErr err; - err = GetWindowProperty(window, - kWidgetCreatorQt, - kWidgetPropertyQWidget, - sizeof(oldwindow), - 0, - &oldwindow); - if (err == noErr) - RemoveWindowProperty(window, kWidgetCreatorQt, kWidgetPropertyQWidget); - - create((WId)root); - - // re-register the root window with Qt - err = SetWindowProperty(window, - kWidgetCreatorQt, - kWidgetPropertyQWidget, - sizeof(oldwindow), - &oldwindow); - if (err != noErr) { - qWarning("Error, couldn't register Window with Qt: (%s:%d:%d)", __FILE__, __LINE__, err); - } - - QPalette pal = palette(); - pal.setColor(QPalette::Window,Qt::transparent); - setPalette(pal); - - setAttribute(Qt::WA_WState_Polished); - } - - ~QMacBrowserRoot() { } -}; -#include "qtbrowserplugin_mac.moc" - -struct key_sym -{ - int mac_code; - int qt_code; - const char *desc; -}; - -static key_sym modifier_syms[] = { -{ shiftKey, Qt::ShiftModifier, "Qt::ShiftModifier" }, -{ controlKey, Qt::MetaModifier, "Qt::MetaModifier" }, -{ rightControlKey, Qt::MetaModifier, "Qt::MetaModifier" }, -{ optionKey, Qt::AltModifier, "Qt::AltModifier" }, -{ rightOptionKey, Qt::AltModifier, "Qt::AltModifier" }, -{ cmdKey, Qt::ControlModifier, "Qt::ControlModifier" }, -{ 0, 0, NULL } -}; -static Qt::KeyboardModifiers get_modifiers(int key) -{ - Qt::KeyboardModifiers ret = 0; - for(int i = 0; modifier_syms[i].desc; i++) { - if(key & modifier_syms[i].mac_code) { - ret |= Qt::KeyboardModifier(modifier_syms[i].qt_code); - } - } - return ret; -} - -static key_sym key_syms[] = { -{ kHomeCharCode, Qt::Key_Home, "Qt::Home" }, -{ kEnterCharCode, Qt::Key_Enter, "Qt::Key_Enter" }, -{ kEndCharCode, Qt::Key_End, "Qt::Key_End" }, -{ kBackspaceCharCode, Qt::Key_Backspace, "Qt::Backspace" }, -{ kTabCharCode, Qt::Key_Tab, "Qt::Tab" }, -{ kPageUpCharCode, Qt::Key_PageUp, "Qt::PageUp" }, -{ kPageDownCharCode, Qt::Key_PageDown, "Qt::PageDown" }, -{ kReturnCharCode, Qt::Key_Return, "Qt::Key_Return" }, -//function keys? -{ kEscapeCharCode, Qt::Key_Escape, "Qt::Key_Escape" }, -{ kLeftArrowCharCode, Qt::Key_Left, "Qt::Key_Left" }, -{ kRightArrowCharCode, Qt::Key_Right, "Qt::Key_Right" }, -{ kUpArrowCharCode, Qt::Key_Up, "Qt::Key_Up" }, -{ kDownArrowCharCode, Qt::Key_Down, "Qt::Key_Down" }, -{ kDeleteCharCode, Qt::Key_Delete, "Qt::Key_Delete" } -}; -static int get_key(int key) -{ - for(int i = 0; key_syms[i].desc; i++) { - if(key_syms[i].mac_code == key) { - return key_syms[i].qt_code; - } - } - return key; -} - -struct qt_last_mouse_down_struct { - unsigned int when; - int x, y; -} qt_last_mouse_down = { 0, 0, 0 }; - -//nasty, copied code - -static void qt_dispatchEnterLeave(QWidget* enter, QWidget* leave) { -#if 0 - if(leave) { - QEvent e(QEvent::Leave); - QApplication::sendEvent(leave, & e); - } - if(enter) { - QEvent e(QEvent::Enter); - QApplication::sendEvent(enter, & e); - } - return; -#endif - - QWidget* w ; - if(!enter && !leave) - return; - QWidgetList leaveList; - QWidgetList enterList; - - bool sameWindow = leave && enter && leave->window() == enter->window(); - if(leave && !sameWindow) { - w = leave; - do { - leaveList.append(w); - } while(!w->isWindow() && (w = w->parentWidget())); - } - if(enter && !sameWindow) { - w = enter; - do { - enterList.prepend(w); - } while(!w->isWindow() && (w = w->parentWidget())); - } - if(sameWindow) { - int enterDepth = 0; - int leaveDepth = 0; - w = enter; - while(!w->isWindow() && (w = w->parentWidget())) - enterDepth++; - w = leave; - while(!w->isWindow() && (w = w->parentWidget())) - leaveDepth++; - QWidget* wenter = enter; - QWidget* wleave = leave; - while(enterDepth > leaveDepth) { - wenter = wenter->parentWidget(); - enterDepth--; - } - while(leaveDepth > enterDepth) { - wleave = wleave->parentWidget(); - leaveDepth--; - } - while(!wenter->isWindow() && wenter != wleave) { - wenter = wenter->parentWidget(); - wleave = wleave->parentWidget(); - } - - w = leave; - while(w != wleave) { - leaveList.append(w); - w = w->parentWidget(); - } - w = enter; - while(w != wenter) { - enterList.prepend(w); - w = w->parentWidget(); - } - } - - QEvent leaveEvent(QEvent::Leave); - for (int i = 0; i < leaveList.size(); ++i) { - w = leaveList.at(i); - QApplication::sendEvent(w, &leaveEvent); -#if 0 - if(w->testAttribute(Qt::WA_Hover)) { - Q_ASSERT(instance()); - QHoverEvent he(QEvent::HoverLeave, QPoint(-1, -1), - w->mapFromGlobal(QApplicationPrivate::instance()->hoverGlobalPos)); - QApplication::sendEvent(w, &he); - } -#endif - } - QPoint posEnter = QCursor::pos(); - QEvent enterEvent(QEvent::Enter); - for (int i = 0; i < enterList.size(); ++i) { - w = enterList.at(i); - QApplication::sendEvent(w, &enterEvent); - if(w->testAttribute(Qt::WA_Hover)) { - QHoverEvent he(QEvent::HoverEnter, w->mapFromGlobal(posEnter), QPoint(-1, -1)); - QApplication::sendEvent(w, &he); - } - } -} - - -extern "C" bool qtns_event(QtNPInstance *This, NPEvent *event) -{ - static QPointer<QWidget> lastWidget; - static QPointer<QWidget> qt_button_down; - static Point lastPosition = { 0, 0 }; - if(event->what == nullEvent || event->what == adjustCursorEvent) { - if(event->what == nullEvent) { - qApp->processEvents(); - QApplication::sendPostedEvents(); - } - - //watch for mouse moves - Point currentPosition; - GetMouse(¤tPosition); - LocalToGlobal(¤tPosition); - if(currentPosition.h != lastPosition.h || currentPosition.v != lastPosition.v) { - lastPosition = currentPosition; - - WindowPtr wp; - FindWindow(currentPosition, &wp); - QWidget *widget = 0; - if(wp == GetWindowFromPort((CGrafPtr)This->window->port)) - widget = This->rootWidget->childAt(This->rootWidget->mapFromGlobal(QPoint(event->where.h, event->where.v))); - else - widget = QApplication::widgetAt(event->where.h, event->where.v); - if(widget != lastWidget) { - qt_dispatchEnterLeave(widget, lastWidget); - lastWidget = widget; - } - if(widget) { - QPoint p(currentPosition.h, currentPosition.v); - QPoint plocal(widget->mapFromGlobal(p)); - QMouseEvent qme(QEvent::MouseMove, plocal, p, Button() ? Qt::LeftButton : Qt::NoButton, - 0, get_modifiers(GetCurrentKeyModifiers())); - QApplication::sendEvent(widget, &qme); - } - } - return true; - } else if(QWidget *widget = qobject_cast<QWidget*>(This->qt.object)) { - if(event->what == updateEvt) { - widget->repaint(); - return true; - } else if(event->what == keyUp || event->what == keyDown) { - QWidget *widget = 0; - if(QWidget::keyboardGrabber()) - widget = QWidget::keyboardGrabber(); - else if(QApplication::focusWidget()) - widget = QApplication::focusWidget(); - else //last ditch effort - widget = QApplication::widgetAt(event->where.h, event->where.v); - - if(widget) { -#if 0 - if(app_do_modal && !qt_try_modal(widget, er)) - return 1; -#endif - - int mychar=get_key(event->message & charCodeMask); - QEvent::Type etype = event->what == keyUp ? QEvent::KeyRelease : QEvent::KeyPress; - QKeyEvent ke(etype, mychar, get_modifiers(event->modifiers), QString(QChar(mychar))); - QApplication::sendEvent(widget,&ke); - return true; - } - } else if(event->what == mouseDown || event->what == mouseUp) { - QEvent::Type etype = QEvent::None; - Qt::KeyboardModifiers keys = get_modifiers(event->modifiers); - Qt::MouseButton button = Qt::LeftButton; - - if(event->what == mouseDown) { - if (lastWidget) - qt_button_down = lastWidget; - //check if this is the second click, there must be a way to make the - //mac do this for us, FIXME!! - if(qt_last_mouse_down.when && - (event->when - qt_last_mouse_down.when <= (uint)QApplication::doubleClickInterval())) { - int x = event->where.h, y = event->where.v; - if(x >= (qt_last_mouse_down.x-2) && x <= (qt_last_mouse_down.x+4) && - y >= (qt_last_mouse_down.y-2) && y <= (qt_last_mouse_down.y+4)) { - etype = QEvent::MouseButtonDblClick; - qt_last_mouse_down.when = 0; - } - } - - if(etype == QEvent::None) { //guess it's just a press - etype = QEvent::MouseButtonPress; - qt_last_mouse_down.when = event->when; - qt_last_mouse_down.x = event->where.h; - qt_last_mouse_down.y = event->where.v; - } - } else { - etype = QEvent::MouseButtonRelease; - } - - WindowPtr wp; - FindWindow(event->where, &wp); - - //handle popup's first - QWidget *popupwidget = NULL; - if(QApplication::activePopupWidget()) { - if(wp) { - QWidget *clt=QWidget::find((WId)wp); - if(clt && clt->windowType() == Qt::Popup) - popupwidget = clt; - } - if(!popupwidget) - popupwidget = QApplication::activePopupWidget(); - if(QWidget *child = popupwidget->childAt(popupwidget->mapFromGlobal(QPoint(event->where.h, event->where.v)))) - popupwidget = child; - - QPoint p(event->where.h, event->where.v); - QPoint plocal(popupwidget->mapFromGlobal(p)); - QMouseEvent qme(etype, plocal, p, button, 0, keys); - QApplication::sendEvent(popupwidget, &qme); - } - - { - QWidget *widget = 0; //figure out which widget to send it to - if(event->what == mouseUp && qt_button_down) - widget = qt_button_down; - else if(QWidget::mouseGrabber()) - widget = QWidget::mouseGrabber(); - else if(wp == GetWindowFromPort((CGrafPtr)This->window->port)) - widget = This->rootWidget->childAt(This->rootWidget->mapFromGlobal(QPoint(event->where.h, event->where.v))); - else - widget = QApplication::widgetAt(event->where.h, event->where.v); - - //setup the saved widget - qt_button_down = event->what == mouseDown ? widget : 0; - - //finally send the event to the widget if its not the popup - if(widget && widget != popupwidget) { -#if 0 - if(app_do_modal && !qt_try_modal(widget, er)) - return 1; -#endif - if(event->what == mouseDown) { - QWidget* w = widget; - while(w->focusProxy()) - w = w->focusProxy(); - if(w->focusPolicy() & Qt::ClickFocus) - w->setFocus(Qt::MouseFocusReason); - if(QWidget *tlw = widget->topLevelWidget()) { - tlw->raise(); - if(tlw->isTopLevel() && tlw->windowType() != Qt::Popup && - (tlw->isModal() || tlw->windowType() != Qt::Dialog)) - QApplication::setActiveWindow(tlw); - } - } - - QPoint p(event->where.h, event->where.v); - QPoint plocal(widget->mapFromGlobal( p )); - QMouseEvent qme(etype, plocal, p, button, 0, keys); - QApplication::sendEvent(widget, &qme); - return true; - } - } - } else { - //qDebug("%d", event->what); - } - } - return false; -} - -#ifdef QTBROWSER_USE_CFM -static bool qtbrowser_use_cfm = false; -static UInt32 gGlueTemplate[6] = { 0x3D800000, 0x618C0000, 0x800C0000, - 0x804C0004, 0x7C0903A6, 0x4E800420 }; -struct TVector_rec -{ - ProcPtr fProcPtr; - void *fTOC; -}; - -void *CFMFunctionPointerForMachOFunctionPointer(void *inMachProcPtr) -{ - if(!qtbrowser_use_cfm) - return inMachProcPtr; - TVector_rec *vTVector = (TVector_rec*)malloc(sizeof(TVector_rec)); - if(MemError() == noErr && vTVector != 0) { - vTVector->fProcPtr = (ProcPtr)inMachProcPtr; - vTVector->fTOC = 0; // ignored - } - return((void *)vTVector); -} - -void DisposeCFMFunctionPointer(void *inCfmProcPtr) -{ - if(!qtbrowser_use_cfm) - return; - if(inCfmProcPtr) - free(inCfmProcPtr); -} - -void* MachOFunctionPointerForCFMFunctionPointer(void* inCfmProcPtr) -{ - if(!qtbrowser_use_cfm) - return inCfmProcPtr; - UInt32 *vMachProcPtr = (UInt32*)NewPtr(sizeof(gGlueTemplate)); - vMachProcPtr[0] = gGlueTemplate[0] | ((UInt32)inCfmProcPtr >> 16); - vMachProcPtr[1] = gGlueTemplate[1] | ((UInt32)inCfmProcPtr & 0xFFFF); - vMachProcPtr[2] = gGlueTemplate[2]; - vMachProcPtr[3] = gGlueTemplate[3]; - vMachProcPtr[4] = gGlueTemplate[4]; - vMachProcPtr[5] = gGlueTemplate[5]; - MakeDataExecutable(vMachProcPtr, sizeof(gGlueTemplate)); - return(vMachProcPtr); -} -#endif - - -extern "C" void qtns_initialize(QtNPInstance *) -{ - qt_mac_set_native_menubar(false); - if(!qApp) { - ownsqapp = true; - static int argc=0; - static char **argv={ 0 }; - (void)new QApplication(argc, argv); - } -} - -extern "C" void qtns_destroy(QtNPInstance *This) -{ - delete This->rootWidget; - This->rootWidget = 0; -} - -extern "C" void qtns_shutdown() -{ - if(!ownsqapp) - return; - - // TODO: find out if other plugin DLL's still need qApp - delete qApp; - ownsqapp = false; -} - -extern "C" void qtns_embed(QtNPInstance *This) -{ - Q_ASSERT(qobject_cast<QWidget*>(This->qt.object)); - - WindowPtr windowptr = GetWindowFromPort((CGrafPtr)This->window->port); - HIViewRef root = 0; - OSErr err; - err = GetRootControl(windowptr,&root); - if(!root) - root = HIViewGetRoot(windowptr); - if(!root) { - qDebug("No window composition!"); - } else { - This->rootWidget = new QMacBrowserRoot(root); - This->qt.widget->setParent(This->rootWidget); - } -} - -extern "C" void qtns_setGeometry(QtNPInstance *This, const QRect &rect, const QRect &clipRect) -{ - Q_ASSERT(qobject_cast<QWidget*>(This->qt.object)); - - WindowPtr windowptr = GetWindowFromPort((CGrafPtr)This->window->port); - Rect content_r; - GetWindowBounds(windowptr, kWindowContentRgn, &content_r); - Rect structure_r; - GetWindowBounds(windowptr, kWindowStructureRgn, &structure_r); - - QRect geom(rect.translated(content_r.left-structure_r.left, content_r.top-structure_r.top)); - if(rect != clipRect) { - QRegion clipRegion(QRect(clipRect.x()-geom.x(), clipRect.y()-geom.y(), clipRect.width(), clipRect.height()) - .translated(content_r.left-structure_r.left, content_r.top-structure_r.top)); - if(clipRegion.isEmpty()) - clipRegion = QRegion(-1, -1, 1, 1); //eww ### FIXME - This->qt.widget->setMask(clipRegion); - } else { - This->qt.widget->clearMask(); - } - This->qt.widget->setGeometry(geom); -} - -typedef void (*NPP_ShutdownUPP)(void); - -extern "C" void NPP_MacShutdown() -{ - //extern NPError NP_Shutdown(); - //NP_Shutdown(); -} - -extern "C" int main(NPNetscapeFuncs *npn_funcs, NPPluginFuncs *np_funcs, NPP_ShutdownUPP *shutdown) -{ - qtbrowser_use_cfm = true; //quite the heuristic.. - - NPError ret; - extern NPError NP_Initialize(NPNetscapeFuncs*); - if((ret=NP_Initialize(npn_funcs)) != NPERR_NO_ERROR) - return ret; - extern NPError NP_GetEntryPoints(NPPluginFuncs*); - if((ret=NP_GetEntryPoints(np_funcs)) != NPERR_NO_ERROR) - return ret; - *shutdown = (NPP_ShutdownUPP)MAKE_FUNCTION_POINTER(NPP_MacShutdown); - return NPERR_NO_ERROR; -} diff --git a/x2gobrowserplugin-2.4_1/src/qtbrowserplugin_p.h b/x2gobrowserplugin-2.4_1/src/qtbrowserplugin_p.h deleted file mode 100644 index ebca24a..0000000 --- a/x2gobrowserplugin-2.4_1/src/qtbrowserplugin_p.h +++ /dev/null @@ -1,94 +0,0 @@ -/**************************************************************************** -** -** Copyright (C) 2009 Nokia Corporation and/or its subsidiary(-ies). -** All rights reserved. -** Contact: Nokia Corporation (qt-info@nokia.com) -** -** This file is part of a Qt Solutions component. -** -** You may use this file under the terms of the BSD license as follows: -** -** "Redistribution and use in source and binary forms, with or without -** modification, are permitted provided that the following conditions are -** met: -** * Redistributions of source code must retain the above copyright -** notice, this list of conditions and the following disclaimer. -** * Redistributions in binary form must reproduce the above copyright -** notice, this list of conditions and the following disclaimer in -** the documentation and/or other materials provided with the -** distribution. -** * Neither the name of Nokia Corporation and its Subsidiary(-ies) nor -** the names of its contributors may be used to endorse or promote -** products derived from this software without specific prior written -** permission. -** -** THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS -** "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT -** LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR -** A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT -** OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, -** SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT -** LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, -** DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY -** THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT -** (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE -** OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE." -** -****************************************************************************/ - -#include <QtCore/QVariant> -#include <QtCore/QMutexLocker> -#include <QtGui/QWidget> - -#ifdef Q_WS_X11 -# include <X11/Xlib.h> -class QtNPStream; -class QtNPBindable; -#endif - - -struct QtNPInstance -{ - NPP npp; - - short fMode; - -#ifdef Q_WS_WIN - typedef HWND Widget; -#endif -#ifdef Q_WS_X11 - typedef Window Widget; - Display *display; -#endif -#ifdef Q_WS_MAC - typedef NPPort* Widget; - QWidget *rootWidget; -#endif - - Widget window; - - QRect geometry; - QString mimetype; - QByteArray htmlID; - union { - QObject* object; - QWidget* widget; - } qt; - QtNPStream *pendingStream; - QtNPBindable* bindable; - QObject *filter; - - QMap<QByteArray, QVariant> parameters; - - qint32 notificationSeqNum; - QMutex seqNumMutex; - qint32 getNotificationSeqNum() - { - QMutexLocker locker(&seqNumMutex); - - if (++notificationSeqNum < 0) - notificationSeqNum = 1; - return notificationSeqNum; - } - -}; diff --git a/x2gobrowserplugin-2.4_1/src/qtbrowserplugin_win.cpp b/x2gobrowserplugin-2.4_1/src/qtbrowserplugin_win.cpp deleted file mode 100644 index a9bb884..0000000 --- a/x2gobrowserplugin-2.4_1/src/qtbrowserplugin_win.cpp +++ /dev/null @@ -1,194 +0,0 @@ -/**************************************************************************** -** -** Copyright (C) 2009 Nokia Corporation and/or its subsidiary(-ies). -** All rights reserved. -** Contact: Nokia Corporation (qt-info@nokia.com) -** -** This file is part of a Qt Solutions component. -** -** You may use this file under the terms of the BSD license as follows: -** -** "Redistribution and use in source and binary forms, with or without -** modification, are permitted provided that the following conditions are -** met: -** * Redistributions of source code must retain the above copyright -** notice, this list of conditions and the following disclaimer. -** * Redistributions in binary form must reproduce the above copyright -** notice, this list of conditions and the following disclaimer in -** the documentation and/or other materials provided with the -** distribution. -** * Neither the name of Nokia Corporation and its Subsidiary(-ies) nor -** the names of its contributors may be used to endorse or promote -** products derived from this software without specific prior written -** permission. -** -** THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS -** "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT -** LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR -** A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT -** OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, -** SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT -** LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, -** DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY -** THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT -** (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE -** OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE." -** -****************************************************************************/ - -#include <QtGui> - -#include "qtbrowserplugin.h" -#include "qtbrowserplugin_p.h" - -#include <windows.h> -#include "qtnpapi.h" - -static HHOOK hhook = 0; -static bool ownsqapp = false; -Q_GUI_EXPORT int qt_translateKeyCode(int); - -LRESULT CALLBACK FilterProc( int nCode, WPARAM wParam, LPARAM lParam ) -{ - if (qApp) - qApp->sendPostedEvents(0, -1); - - if (nCode < 0 || !(wParam & PM_REMOVE)) - return CallNextHookEx(hhook, nCode, wParam, lParam); - - MSG *msg = (MSG*)lParam; - bool processed = false; - - // (some) support for key-sequences via QAction and QShortcut - if(msg->message == WM_KEYDOWN || msg->message == WM_SYSKEYDOWN) { - QWidget *focusWidget = QWidget::find(msg->hwnd); - if (focusWidget) { - int key = msg->wParam; - if (!(key >= 'A' && key <= 'Z') && !(key >= '0' && key <= '9')) - key = qt_translateKeyCode(msg->wParam); - - Qt::KeyboardModifiers modifiers = 0; - int modifierKey = 0; - if (GetKeyState(VK_SHIFT) < 0) { - modifierKey |= Qt::SHIFT; - modifiers |= Qt::ShiftModifier; - } - if (GetKeyState(VK_CONTROL) < 0) { - modifierKey |= Qt::CTRL; - modifiers |= Qt::ControlModifier; - } - if (GetKeyState(VK_MENU) < 0) { - modifierKey |= Qt::ALT; - modifiers |= Qt::AltModifier; - } - QKeySequence shortcutKey(modifierKey + key); - if (!shortcutKey.isEmpty()) { - QKeyEvent override(QEvent::ShortcutOverride, key, modifiers); - override.ignore(); - QApplication::sendEvent(focusWidget, &override); - processed = override.isAccepted(); - - if (!processed) { - QList<QAction*> actions = qFindChildren<QAction*>(focusWidget->window()); - for (int i = 0; i < actions.count() && !processed; ++i) { - QAction *action = actions.at(i); - if (!action->isEnabled() || action->shortcut() != shortcutKey) - continue; - QShortcutEvent event(shortcutKey, 0); - processed = QApplication::sendEvent(action, &event); - } - } - if (!processed) { - QList<QShortcut*> shortcuts = qFindChildren<QShortcut*>(focusWidget->window()); - for (int i = 0; i < shortcuts.count() && !processed; ++i) { - QShortcut *shortcut = shortcuts.at(i); - if (!shortcut->isEnabled() || shortcut->key() != shortcutKey) - continue; - QShortcutEvent event(shortcutKey, shortcut->id()); - processed = QApplication::sendEvent(shortcut, &event); - } - } - } - } - } - - return CallNextHookEx(hhook, nCode, wParam, lParam); -} - -extern "C" bool qtns_event(QtNPInstance *, NPEvent *) -{ - return false; -} - -extern Q_CORE_EXPORT void qWinMsgHandler(QtMsgType t, const char* str); - -extern "C" void qtns_initialize(QtNPInstance*) -{ - if (!qApp) { - qInstallMsgHandler(qWinMsgHandler); - ownsqapp = true; - static int argc=0; - static char **argv={ 0 }; - (void)new QApplication(argc, argv); - - QT_WA({ - hhook = SetWindowsHookExW( WH_GETMESSAGE, FilterProc, 0, GetCurrentThreadId() ); - }, { - hhook = SetWindowsHookExA( WH_GETMESSAGE, FilterProc, 0, GetCurrentThreadId() ); - }); - } -} - -extern "C" void qtns_destroy(QtNPInstance *) -{ -} - -extern "C" void qtns_shutdown() -{ - if (!ownsqapp) - return; - - // check if qApp still runs widgets (in other DLLs) - QWidgetList widgets = qApp->allWidgets(); - int count = widgets.count(); - for (int w = 0; w < widgets.count(); ++w) { - // ignore all Qt generated widgets - QWidget *widget = widgets.at(w); - if (widget->windowFlags() & Qt::Desktop) - count--; - } - if (count) // qApp still used - return; - - delete qApp; - ownsqapp = false; - if ( hhook ) - UnhookWindowsHookEx( hhook ); - hhook = 0; -} - -extern "C" void qtns_embed(QtNPInstance *This) -{ - Q_ASSERT(qobject_cast<QWidget*>(This->qt.object)); - - LONG oldLong = GetWindowLong(This->window, GWL_STYLE); - ::SetWindowLong(This->window, GWL_STYLE, oldLong | WS_CLIPCHILDREN | WS_CLIPSIBLINGS); - ::SetWindowLong(This->qt.widget->winId(), GWL_STYLE, WS_CHILD | WS_CLIPCHILDREN | WS_CLIPSIBLINGS); - ::SetParent(This->qt.widget->winId(), This->window); -} - -extern "C" void qtns_setGeometry(QtNPInstance *This, const QRect &rect, const QRect &) -{ - Q_ASSERT(qobject_cast<QWidget*>(This->qt.object)); - - This->qt.widget->setGeometry(QRect(0, 0, rect.width(), rect.height())); -} - -/* -extern "C" void qtns_print(QtNPInstance * This, NPPrint *printInfo) -{ - NPWindow* printWindow = &(printInfo->print.embedPrint.window); - void* platformPrint = printInfo->print.embedPrint.platformPrint; - // #### Nothing yet. -} -*/ diff --git a/x2gobrowserplugin-2.4_1/src/qtbrowserplugin_x11.cpp b/x2gobrowserplugin-2.4_1/src/qtbrowserplugin_x11.cpp deleted file mode 100644 index c988a34..0000000 --- a/x2gobrowserplugin-2.4_1/src/qtbrowserplugin_x11.cpp +++ /dev/null @@ -1,150 +0,0 @@ -/**************************************************************************** -** -** Copyright (C) 2009 Nokia Corporation and/or its subsidiary(-ies). -** All rights reserved. -** Contact: Nokia Corporation (qt-info@nokia.com) -** -** This file is part of a Qt Solutions component. -** -** You may use this file under the terms of the BSD license as follows: -** -** "Redistribution and use in source and binary forms, with or without -** modification, are permitted provided that the following conditions are -** met: -** * Redistributions of source code must retain the above copyright -** notice, this list of conditions and the following disclaimer. -** * Redistributions in binary form must reproduce the above copyright -** notice, this list of conditions and the following disclaimer in -** the documentation and/or other materials provided with the -** distribution. -** * Neither the name of Nokia Corporation and its Subsidiary(-ies) nor -** the names of its contributors may be used to endorse or promote -** products derived from this software without specific prior written -** permission. -** -** THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS -** "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT -** LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR -** A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT -** OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, -** SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT -** LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, -** DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY -** THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT -** (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE -** OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE." -** -****************************************************************************/ - -#include <QtGui> -#include <QtGui/QX11EmbedWidget> - -#include "qtbrowserplugin.h" -#include "qtbrowserplugin_p.h" - -#include "qtnpapi.h" - -#include <stdlib.h> - -static bool ownsqapp = false; -static QMap<QtNPInstance*, QX11EmbedWidget*> clients; - -extern "C" bool qtns_event(QtNPInstance *, NPEvent *) -{ - return false; -} - -extern "C" void qtns_initialize(QtNPInstance* This) -{ - if (!qApp) { - ownsqapp = true; - static int argc = 0; - static char **argv = {0}; - - // Workaround to avoid re-initilaziation of glib - char* envvar = qstrdup("QT_NO_THREADED_GLIB=1"); - // Unavoidable memory leak; the variable must survive plugin unloading - ::putenv(envvar); - - (void)new QApplication(argc, argv); - } - if (!clients.contains(This)) { - QX11EmbedWidget* client = new QX11EmbedWidget; - QHBoxLayout* layout = new QHBoxLayout(client); - layout->setMargin(0); - clients.insert(This, client); - } -} - -extern "C" void qtns_destroy(QtNPInstance* This) -{ - QMap<QtNPInstance*, QX11EmbedWidget*>::iterator it = clients.find(This); - if (it == clients.end()) - return; - delete it.value(); - clients.erase(it); -} - -extern "C" void qtns_shutdown() -{ - if (clients.count() > 0) { - QMap<QtNPInstance*, QX11EmbedWidget*>::iterator it = clients.begin(); - while (it != clients.end()) { - delete it.value(); - ++it; - } - clients.clear(); - } - - if (!ownsqapp) - return; - - // check if qApp still runs widgets (in other DLLs) - QWidgetList widgets = qApp->allWidgets(); - int count = widgets.count(); - for (int w = 0; w < widgets.count(); ++w) { - // ignore all Qt generated widgets - QWidget *widget = widgets.at(w); - if (widget->windowFlags() & Qt::Desktop) - count--; - } - if (count) // qApp still used - return; - - delete qApp; - ownsqapp = false; -} - -extern "C" void qtns_embed(QtNPInstance *This) -{ - Q_ASSERT(qobject_cast<QWidget*>(This->qt.object)); - - QMap<QtNPInstance*, QX11EmbedWidget*>::iterator it = clients.find(This); - if (it == clients.end()) - return; - QX11EmbedWidget* client = it.value(); - This->qt.widget->setParent(client); - client->layout()->addWidget(This->qt.widget); - client->embedInto(This->window); - client->show(); -} - -extern "C" void qtns_setGeometry(QtNPInstance *This, const QRect &rect, const QRect &) -{ - Q_ASSERT(qobject_cast<QWidget*>(This->qt.object)); - - QMap<QtNPInstance*, QX11EmbedWidget*>::iterator it = clients.find(This); - if (it == clients.end()) - return; - QX11EmbedWidget* client = it.value(); - client->setGeometry(QRect(0, 0, rect.width(), rect.height())); -} - -/* -extern "C" void qtns_print(QtNPInstance * This, NPPrint *printInfo) -{ - NPWindow* printWindow = &(printInfo->print.embedPrint.window); - void* platformPrint = printInfo->print.embedPrint.platformPrint; - // #### Nothing yet. -} -*/ diff --git a/x2gobrowserplugin-2.4_1/src/qtbrowserpluginax.def b/x2gobrowserplugin-2.4_1/src/qtbrowserpluginax.def deleted file mode 100644 index df2dedb..0000000 --- a/x2gobrowserplugin-2.4_1/src/qtbrowserpluginax.def +++ /dev/null @@ -1,9 +0,0 @@ -EXPORTS - NP_GetEntryPoints @1 - NP_Initialize @2 - NP_Shutdown @3 - DllCanUnloadNow PRIVATE - DllGetClassObject PRIVATE - DllRegisterServer PRIVATE - DllUnregisterServer PRIVATE - DumpIDL PRIVATE diff --git a/x2gobrowserplugin-2.4_1/src/qtnpapi.h b/x2gobrowserplugin-2.4_1/src/qtnpapi.h deleted file mode 100644 index d9b5357..0000000 --- a/x2gobrowserplugin-2.4_1/src/qtnpapi.h +++ /dev/null @@ -1,555 +0,0 @@ -/**************************************************************************** -** -** Copyright (C) 2009 Nokia Corporation and/or its subsidiary(-ies). -** All rights reserved. -** Contact: Nokia Corporation (qt-info@nokia.com) -** -** This file is part of a Qt Solutions component. -** -** You may use this file under the terms of the BSD license as follows: -** -** "Redistribution and use in source and binary forms, with or without -** modification, are permitted provided that the following conditions are -** met: -** * Redistributions of source code must retain the above copyright -** notice, this list of conditions and the following disclaimer. -** * Redistributions in binary form must reproduce the above copyright -** notice, this list of conditions and the following disclaimer in -** the documentation and/or other materials provided with the -** distribution. -** * Neither the name of Nokia Corporation and its Subsidiary(-ies) nor -** the names of its contributors may be used to endorse or promote -** products derived from this software without specific prior written -** permission. -** -** THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS -** "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT -** LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR -** A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT -** OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, -** SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT -** LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, -** DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY -** THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT -** (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE -** OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE." -** -****************************************************************************/ - -// see http://www.mozilla.org/projects/plugins/ for details regarding the structs and API prototypes - -#ifndef QTNPAPI_H -#define QTNPAPI_H - -// Plugin API version -#define NP_VERSION_MAJOR 0 -#define NP_VERSION_MINOR 17 - -// basic types -typedef unsigned short uint16; -typedef short int16; -typedef unsigned int uint32; -typedef int int32; - -typedef unsigned char NPBool; -typedef int16 NPError; -typedef int16 NPReason; -typedef char* NPMIMEType; - -typedef void *NPRegion; -typedef void *NPIdentifier; - -// Java stuff -typedef void* jref; -typedef void* JRIGlobalRef; -typedef void* JRIEnv; // ### not quite correct, but we don't use it anyway - -// NP-types -struct NPP_t -{ - void* pdata; // plug-in private data - void* ndata; // browser private data -}; -typedef NPP_t* NPP; - -struct NPRect -{ - uint16 top; - uint16 left; - uint16 bottom; - uint16 right; -}; - -#ifdef Q_WS_WIN -struct NPEvent -{ - uint16 event; - uint32 wParam; - uint32 lParam; -}; -#elif defined(Q_WS_X11) -# include <X11/Xlib.h> -typedef XEvent NPEvent; -#elif defined (Q_WS_MAC) -typedef struct EventRecord NPEvent; -#endif - -// Variable names for NPP_GetValue -enum NPPVariable { - NPPVpluginNameString = 1, - NPPVpluginDescriptionString, - NPPVpluginWindowBool, - NPPVpluginTransparentBool, - NPPVjavaClass, - NPPVpluginWindowSize, - NPPVpluginTimerInterval, - - NPPVpluginScriptableInstance = 10, - NPPVpluginScriptableIID = 11, - - // Introduced in Mozilla 0.9.9 - NPPVjavascriptPushCallerBool = 12, - - // Introduced in Mozilla 1.0 - NPPVpluginKeepLibraryInMemory = 13, - NPPVpluginNeedsXEmbed = 14, - - // Introduced in Firefox 1.0 - NPPVpluginScriptableNPObject = 15, - NPPVformValue = 16 -} ; - -// Variable names for NPN_GetValue -enum NPNVariable { - NPNVxDisplay = 1, - NPNVxtAppContext, - NPNVnetscapeWindow, - NPNVjavascriptEnabledBool, - NPNVasdEnabledBool, - NPNVisOfflineBool, - - // Introduced in Mozilla 0.9.4 - NPNVserviceManager = 10, - NPNVDOMElement = 11, - // Introduced in Mozilla 1.2 - NPNVDOMWindow = 12, - NPNVToolkit = 13, - NPNVSupportsXEmbedBool = 14, - - NPNVWindowNPObject = 15, - NPNVPluginElementNPObject = 16 -}; - - -enum NPWindowType { - NPWindowTypeWindow = 1, // Windowed plug-in. The window field holds a platform-specific handle to a window. - NPWindowTypeDrawable // Windows: HDC; Mac OS: pointer to NP_Port structure. -}; - -struct NPWindow -{ - // Platform-specific handle to a native window element in the browser's window hierarchy - // XEmbed: "In the NPP_SetWindow call, the window parameter will be the XID of the hosting - // XEmbed window. As an implementation note, this is really the XID of a GtkSocket window." - void* window; - // The x and y coordinates for the top left corner of the plug-in relative to the page - // (and thus relative to the origin of the drawable) - uint32 x, y; - // The height and width of the plug-in area. Should not be modified by the plug-in. - uint32 width, height; - // Used by MAC only (Clipping rectangle in port coordinates) - NPRect clipRect; -#ifdef Q_WS_X11 - // Contains information about the plug-in's Unix window environment - // points to an NPSetWindowCallbackStruct - void* ws_info; // probably obsolete with XEmbed -#endif - // The type field indicates the NPWindow type of the target area - NPWindowType type; -}; - -struct NPPort -{ - void *port; - int32 portx; - int32 porty; -}; - -struct NPFullPrint -{ - NPBool pluginPrinted; // true if plugin handled fullscreen printing - NPBool printOne; // true if plugin should print one copy to default printer - void* platformPrint; // Platform-specific printing info -}; - -struct NPEmbedPrint -{ - NPWindow window; - void* platformPrint; // Platform-specific printing info -}; - -struct NPPrint -{ - uint16 mode; // NP_FULL or NP_EMBED - union { - NPFullPrint fullPrint; - NPEmbedPrint embedPrint; - } print; -}; - -struct NPSavedData -{ - int32 len; - void* buf; -}; - -struct NPStream -{ - void* pdata; - void* ndata; - const char* url; - uint32 end; - uint32 lastmodified; - void* notifyData; -}; - -struct NPByteRange -{ - int32 offset; // negative offset means from the end - uint32 length; - NPByteRange* next; -}; - -// Values for mode passed to NPP_New: -#define NP_EMBED 1 -#define NP_FULL 2 - -// Values for stream type passed to NPP_NewStream: -#define NP_NORMAL 1 -#define NP_SEEK 2 -#define NP_ASFILE 3 -#define NP_ASFILEONLY 4 - -#define NP_MAXREADY (((unsigned)(~0)<<1)>>1) - -// Values of type NPError: -#define NPERR_NO_ERROR 0 -#define NPERR_GENERIC_ERROR 1 -#define NPERR_INVALID_INSTANCE_ERROR 2 -#define NPERR_INVALID_FUNCTABLE_ERROR 3 -#define NPERR_MODULE_LOAD_FAILED_ERROR 4 -#define NPERR_OUT_OF_MEMORY_ERROR 5 -#define NPERR_INVALID_PLUGIN_ERROR 6 -#define NPERR_INVALID_PLUGIN_DIR_ERROR 7 -#define NPERR_INCOMPATIBLE_VERSION_ERROR 8 -#define NPERR_INVALID_PARAM 9 -#define NPERR_INVALID_URL 10 -#define NPERR_FILE_NOT_FOUND 11 -#define NPERR_NO_DATA 12 -#define NPERR_STREAM_NOT_SEEKABLE 13 - -// Values of type NPReason: -#define NPRES_DONE 0 -#define NPRES_NETWORK_ERR 1 -#define NPRES_USER_BREAK 2 - -// Version feature information -#define NPVERS_HAS_STREAMOUTPUT 8 -#define NPVERS_HAS_NOTIFICATION 9 -#define NPVERS_HAS_LIVECONNECT 9 -#define NPVERS_WIN16_HAS_LIVECONNECT 10 - -// Mac specifics -#ifdef Q_WS_MAC -# define getFocusEvent (osEvt + 16) -# define loseFocusEvent (osEvt + 17) -# define adjustCursorEvent (osEvt + 18) -# define QTBROWSER_USE_CFM -#endif - -#ifdef QTBROWSER_USE_CFM - extern void *CFMFunctionPointerForMachOFunctionPointer(void*); - extern void DisposeCFMFunctionPointer(void *); - extern void* MachOFunctionPointerForCFMFunctionPointer(void*); -# define FUNCTION_POINTER(t) void* -# define MAKE_FUNCTION_POINTER(f) CFMFunctionPointerForMachOFunctionPointer((void*)f) -# define DESTROY_FUNCTION_POINTER(n) DisposeCFMFunctionPointer(n) -# define FIND_FUNCTION_POINTER(t, n) (*(t)MachOFunctionPointerForCFMFunctionPointer(n)) -#else -# define FUNCTION_POINTER(t) t -# define MAKE_FUNCTION_POINTER(f) f -# define DESTROY_FUNCTION_POINTER(n) -# define FIND_FUNCTION_POINTER(t, n) (*n) -#endif - -// Plugin function prototypes -typedef NPError (*NPP_NewFP)(NPMIMEType pluginType, NPP instance, uint16 mode, int16 argc, char* argn[], char* argv[], NPSavedData* saved); -typedef NPError (*NPP_DestroyFP)(NPP instance, NPSavedData** save); -typedef NPError (*NPP_SetWindowFP)(NPP instance, NPWindow* window); -typedef NPError (*NPP_NewStreamFP)(NPP instance, NPMIMEType type, NPStream* stream, NPBool seekable, uint16* stype); -typedef NPError (*NPP_DestroyStreamFP)(NPP instance, NPStream* stream, NPReason reason); -typedef void (*NPP_StreamAsFileFP)(NPP instance, NPStream* stream, const char* fname); -typedef int32 (*NPP_WriteReadyFP)(NPP instance, NPStream* stream); -typedef int32 (*NPP_WriteFP)(NPP instance, NPStream* stream, int32 offset, int32 len, void* buffer); -typedef void (*NPP_PrintFP)(NPP instance, NPPrint* platformPrint); -typedef int16 (*NPP_HandleEventFP)(NPP instance, NPEvent* event); -typedef void (*NPP_URLNotifyFP)(NPP instance, const char* url, NPReason reason, void* notifyData); -typedef NPError (*NPP_GetValueFP)(NPP instance, NPPVariable variable, void *value); -typedef NPError (*NPP_SetValueFP)(NPP instance, NPPVariable variable, void *value); - -// table of functions implemented by the plugin -struct NPPluginFuncs { - uint16 size; - uint16 version; - FUNCTION_POINTER(NPP_NewFP) newp; - FUNCTION_POINTER(NPP_DestroyFP) destroy; - FUNCTION_POINTER(NPP_SetWindowFP) setwindow; - FUNCTION_POINTER(NPP_NewStreamFP) newstream; - FUNCTION_POINTER(NPP_DestroyStreamFP) destroystream; - FUNCTION_POINTER(NPP_StreamAsFileFP) asfile; - FUNCTION_POINTER(NPP_WriteReadyFP) writeready; - FUNCTION_POINTER(NPP_WriteFP) write; - FUNCTION_POINTER(NPP_PrintFP) print; - FUNCTION_POINTER(NPP_HandleEventFP) event; - FUNCTION_POINTER(NPP_URLNotifyFP) urlnotify; - JRIGlobalRef javaClass; - FUNCTION_POINTER(NPP_GetValueFP) getvalue; - FUNCTION_POINTER(NPP_SetValueFP) setvalue; -} ; - - -// forward declarations -struct NPObject; -struct NPClass; -struct NPVariant; -struct NPString; -struct QtNPInstance; - -// NPObject is the type used to express objects exposed by either -// the plugin or by the browser. Implementation specific (i.e. plugin -// specific, or browser specific) members can come after the struct. -// In our case, the plugin specific member (aka QObject) lives in NPClass. -struct NPObject -{ - NPClass *_class; - uint32 refCount; -}; - -// NPClass is what virtual function tables would look like if -// there was no C++... -typedef NPObject *(*NPAllocateFP)(NPP npp, NPClass *aClass); -typedef void (*NPDeallocateFP)(NPObject *npobj); -typedef void (*NPInvalidateFP)(NPObject *npobj); -typedef bool (*NPHasMethodFP)(NPObject *npobj, NPIdentifier name); -typedef bool (*NPInvokeFP)(NPObject *npobj, NPIdentifier name,const NPVariant *args, uint32 argCount,NPVariant *result); -typedef bool (*NPInvokeDefaultFP)(NPObject *npobj,const NPVariant *args,uint32 argCount,NPVariant *result); -typedef bool (*NPHasPropertyFP)(NPObject *npobj, NPIdentifier name); -typedef bool (*NPGetPropertyFP)(NPObject *npobj, NPIdentifier name, NPVariant *result); -typedef bool (*NPSetPropertyFP)(NPObject *npobj, NPIdentifier name, const NPVariant *value); -typedef bool (*NPRemovePropertyFP)(NPObject *npobj, NPIdentifier name); - -#define NP_CLASS_STRUCT_VERSION 1 - -struct NPClass -{ - NPClass(QtNPInstance *qtnp); - ~NPClass(); - - // NP API - uint32 structVersion; - NPAllocateFP allocate; - NPDeallocateFP deallocate; - NPInvalidateFP invalidate; - NPHasMethodFP hasMethod; - NPInvokeFP invoke; - NPInvokeDefaultFP invokeDefault; - NPHasPropertyFP hasProperty; - NPGetPropertyFP getProperty; - NPSetPropertyFP setProperty; - NPRemovePropertyFP removeProperty; - - // User data lives here - QtNPInstance *qtnp; - bool delete_qtnp; -}; - -struct NPString { - const char *utf8characters; - uint32 utf8length; - - // Qt specific conversion routines - // (no c'tor as it would be misleading that there is no d'tor in spite of memory allocation) - static NPString fromQString(const QString &qstr); - operator QString() const; -}; - -struct NPVariant { - enum Type { - Void, - Null, - Boolean, - Int32, - Double, - String, - Object - }; - Type type; - union { - bool boolValue; - uint32 intValue; - double doubleValue; - NPString stringValue; - NPObject *objectValue; - } value; - - NPVariant() - : type(Null) - {} - - // Qt specific conversion routines - // (no c'tor as the NPP instance is required) - static NPVariant fromQVariant(QtNPInstance *This, const QVariant &qvariant); - operator QVariant() const; - -private: -}; - -#ifdef Q_WS_X11 -extern "C" { -#endif - -// Browser function prototypes -typedef NPError (*NPN_GetURLFP)(NPP instance, const char* url, const char* window); -typedef NPError (*NPN_PostURLFP)(NPP instance, const char* url, const char* window, uint32 len, const char* buf, NPBool file); -typedef NPError (*NPN_RequestReadFP)(NPStream* stream, NPByteRange* rangeList); -typedef NPError (*NPN_NewStreamFP)(NPP instance, NPMIMEType type, const char* window, NPStream** stream); -typedef int32 (*NPN_WriteFP)(NPP instance, NPStream* stream, int32 len, void* buffer); -typedef NPError (*NPN_DestroyStreamFP)(NPP instance, NPStream* stream, NPReason reason); -typedef void (*NPN_StatusFP)(NPP instance, const char* message); -typedef const char* (*NPN_UserAgentFP)(NPP instance); -typedef void* (*NPN_MemAllocFP)(uint32 size); -typedef void (*NPN_MemFreeFP)(void* ptr); -typedef uint32 (*NPN_MemFlushFP)(uint32 size); -typedef void (*NPN_ReloadPluginsFP)(NPBool reloadPages); -typedef JRIEnv* (*NPN_GetJavaEnvFP)(void); -typedef jref (*NPN_GetJavaPeerFP)(NPP instance); -typedef NPError (*NPN_GetURLNotifyFP)(NPP instance, const char* url, const char* window, void* notifyData); -typedef NPError (*NPN_PostURLNotifyFP)(NPP instance, const char* url, const char* window, uint32 len, const char* buf, NPBool file, void* notifyData); -typedef NPError (*NPN_GetValueFP)(NPP instance, NPNVariable variable, void *ret_value); -typedef NPError (*NPN_SetValueFP)(NPP instance, NPPVariable variable, void *ret_value); -typedef void (*NPN_InvalidateRectFP)(NPP instance, NPRect *rect); -typedef void (*NPN_InvalidateRegionFP)(NPP instance, NPRegion *region); -typedef void (*NPN_ForceRedrawFP)(NPP instance); -typedef NPIdentifier (*NPN_GetStringIdentifierFP)(const char* name); -typedef void (*NPN_GetStringIdentifiersFP)(const char** names, int32 nameCount, NPIdentifier* identifiers); -typedef NPIdentifier (*NPN_GetIntIdentifierFP)(int32 intid); -typedef bool (*NPN_IdentifierIsStringFP)(NPIdentifier identifier); -typedef char* (*NPN_UTF8FromIdentifierFP)(NPIdentifier identifier); -typedef int32 (*NPN_IntFromIdentifierFP)(NPIdentifier identifier); -typedef NPObject* (*NPN_CreateObjectFP)(NPP npp, NPClass *aClass); -typedef NPObject* (*NPN_RetainObjectFP)(NPObject *obj); -typedef void (*NPN_ReleaseObjectFP)(NPObject *obj); -typedef bool (*NPN_InvokeFP)(NPP npp, NPObject* obj, NPIdentifier methodName, const NPVariant *args, int32 argCount, NPVariant *result); -typedef bool (*NPN_InvokeDefaultFP)(NPP npp, NPObject* obj, const NPVariant *args, int32 argCount, NPVariant *result); -typedef bool (*NPN_EvaluateFP)(NPP npp, NPObject *obj, NPString *script, NPVariant *result); -typedef bool (*NPN_GetPropertyFP)(NPP npp, NPObject *obj, NPIdentifier propertyName, NPVariant *result); -typedef bool (*NPN_SetPropertyFP)(NPP npp, NPObject *obj, NPIdentifier propertyName, const NPVariant *value); -typedef bool (*NPN_RemovePropertyFP)(NPP npp, NPObject *obj, NPIdentifier propertyName); -typedef bool (*NPN_HasPropertyFP)(NPP npp, NPObject *obj, NPIdentifier propertyName); -typedef bool (*NPN_HasMethodFP)(NPP npp, NPObject *obj, NPIdentifier methodName); -typedef void (*NPN_ReleaseVariantValueFP)(NPVariant *variant); -typedef void (*NPN_SetExceptionFP)(NPObject *obj, const char *message); - -// function declarations -NPError NPN_GetURL(NPP instance, const char* url, const char* window); -NPError NPN_PostURL(NPP instance, const char* url, const char* window, uint32 len, const char* buf, NPBool file); -NPError NPN_RequestRead(NPStream* stream, NPByteRange* rangeList); -NPError NPN_NewStream(NPP instance, NPMIMEType type, const char* window, NPStream** stream); -int32 NPN_Write(NPP instance, NPStream* stream, int32 len, void* buffer); -NPError NPN_DestroyStream(NPP instance, NPStream* stream, NPReason reason); -void NPN_Status(NPP instance, const char* message); -const char* NPN_UserAgent(NPP instance); -void* NPN_MemAlloc(uint32 size); -void NPN_MemFree(void* ptr); -uint32 NPN_MemFlush(uint32 size); -void NPN_ReloadPlugins(NPBool reloadPages); -JRIEnv* NPN_GetJavaEnv(void); -jref NPN_GetJavaPeer(NPP instance); -NPError NPN_GetURLNotify(NPP instance, const char* url, const char* window, void* notifyData); -NPError NPN_PostURLNotify(NPP instance, const char* url, const char* window, uint32 len, const char* buf, NPBool file, void* notifyData); -NPError NPN_GetValue(NPP instance, NPNVariable variable, void *ret_value); -NPError NPN_SetValue(NPP instance, NPPVariable variable, void *ret_value); -void NPN_InvalidateRect(NPP instance, NPRect *rect); -void NPN_InvalidateRegion(NPP instance, NPRegion *region); -void NPN_ForceRedraw(NPP instance); -NPIdentifier NPN_GetStringIdentifier(const char* name); -void NPN_GetStringIdentifiers(const char** names, int32 nameCount, NPIdentifier* identifiers); -NPIdentifier NPN_GetIntIdentifier(int32 intid); -bool NPN_IdentifierIsString(NPIdentifier identifier); -char* NPN_UTF8FromIdentifier(NPIdentifier identifier); -int32 NPN_IntFromIdentifier(NPIdentifier identifier); -NPObject* NPN_CreateObject(NPP npp, NPClass *aClass); -NPObject* NPN_RetainObject(NPObject *obj); -void NPN_ReleaseObject(NPObject *obj); -bool NPN_Invoke(NPP npp, NPObject* obj, NPIdentifier methodName, const NPVariant *args, int32 argCount, NPVariant *result); -bool NPN_InvokeDefault(NPP npp, NPObject* obj, const NPVariant *args, int32 argCount, NPVariant *result); -bool NPN_Evaluate(NPP npp, NPObject *obj, NPString *script, NPVariant *result); -bool NPN_GetProperty(NPP npp, NPObject *obj, NPIdentifier propertyName, NPVariant *result); -bool NPN_SetProperty(NPP npp, NPObject *obj, NPIdentifier propertyName, const NPVariant *value); -bool NPN_RemoveProperty(NPP npp, NPObject *obj, NPIdentifier propertyName); -bool NPN_HasProperty(NPP npp, NPObject *obj, NPIdentifier propertyName); -bool NPN_HasMethod(NPP npp, NPObject *obj, NPIdentifier methodName); -void NPN_ReleaseVariantValue(NPVariant *variant); -void NPN_SetException(NPObject *obj, const char *message); - -// table of function implemented by the browser -struct NPNetscapeFuncs { - uint16 size; - uint16 version; - FUNCTION_POINTER(NPN_GetURLFP) geturl; - FUNCTION_POINTER(NPN_PostURLFP) posturl; - FUNCTION_POINTER(NPN_RequestReadFP) requestread; - FUNCTION_POINTER(NPN_NewStreamFP) newstream; - FUNCTION_POINTER(NPN_WriteFP) write; - FUNCTION_POINTER(NPN_DestroyStreamFP) destroystream; - FUNCTION_POINTER(NPN_StatusFP) status; - FUNCTION_POINTER(NPN_UserAgentFP) uagent; - FUNCTION_POINTER(NPN_MemAllocFP) memalloc; - FUNCTION_POINTER(NPN_MemFreeFP) memfree; - FUNCTION_POINTER(NPN_MemFlushFP) memflush; - FUNCTION_POINTER(NPN_ReloadPluginsFP) reloadplugins; - FUNCTION_POINTER(NPN_GetJavaEnvFP) getJavaEnv; - FUNCTION_POINTER(NPN_GetJavaPeerFP) getJavaPeer; - FUNCTION_POINTER(NPN_GetURLNotifyFP) geturlnotify; - FUNCTION_POINTER(NPN_PostURLNotifyFP) posturlnotify; - FUNCTION_POINTER(NPN_GetValueFP) getvalue; - FUNCTION_POINTER(NPN_SetValueFP) setvalue; - FUNCTION_POINTER(NPN_InvalidateRectFP) invalidaterect; - FUNCTION_POINTER(NPN_InvalidateRegionFP) invalidateregion; - FUNCTION_POINTER(NPN_ForceRedrawFP) forceredraw; - FUNCTION_POINTER(NPN_GetStringIdentifierFP) getstringidentifier; - FUNCTION_POINTER(NPN_GetStringIdentifiersFP) getstringidentifiers; - FUNCTION_POINTER(NPN_GetIntIdentifierFP) getintidentifier; - FUNCTION_POINTER(NPN_IdentifierIsStringFP) identifierisstring; - FUNCTION_POINTER(NPN_UTF8FromIdentifierFP) utf8fromidentifier; - FUNCTION_POINTER(NPN_IntFromIdentifierFP) intfromidentifier; - FUNCTION_POINTER(NPN_CreateObjectFP) createobject; - FUNCTION_POINTER(NPN_RetainObjectFP) retainobject; - FUNCTION_POINTER(NPN_ReleaseObjectFP) releaseobject; - FUNCTION_POINTER(NPN_InvokeFP) invoke; - FUNCTION_POINTER(NPN_InvokeDefaultFP) invokedefault; - FUNCTION_POINTER(NPN_EvaluateFP) evaluate; - FUNCTION_POINTER(NPN_GetPropertyFP) getproperty; - FUNCTION_POINTER(NPN_SetPropertyFP) setproperty; - FUNCTION_POINTER(NPN_RemovePropertyFP) removeproperty; - FUNCTION_POINTER(NPN_HasPropertyFP) hasproperty; - FUNCTION_POINTER(NPN_HasMethodFP) hasmethod; - FUNCTION_POINTER(NPN_ReleaseVariantValueFP) releasevariantvalue; - FUNCTION_POINTER(NPN_SetExceptionFP) setexception; -}; - -#ifdef Q_WS_X11 -} -#endif - -#endif diff --git a/x2gobrowserplugin-2.4_1/src/res/x2goplugin.rc b/x2gobrowserplugin-2.4_1/src/res/x2goplugin.rc deleted file mode 100644 index c037281..0000000 --- a/x2gobrowserplugin-2.4_1/src/res/x2goplugin.rc +++ /dev/null @@ -1,37 +0,0 @@ -1 TYPELIB "x2goplugin.rc" - -1 VERSIONINFO - FILEVERSION 4.1.2.0 - PRODUCTVERSION 4.1.2.0 - FILEFLAGSMASK 0x3fL -#ifdef _DEBUG - FILEFLAGS 0x1L -#else - FILEFLAGS 0x0L -#endif - FILEOS 0x4L - FILETYPE 0x2L - FILESUBTYPE 0x0L -BEGIN - BLOCK "StringFileInfo" - BEGIN - BLOCK "040904e4" - BEGIN - VALUE "CompanyName", "Obviously Nice\0" - VALUE "FileDescription", "Allows you to start X2Go session in a webbrowser\0" - VALUE "FileExtents", "x2go\0" - VALUE "FileOpenName", "Configuration File for X2Go Session (*.x2go)\0" - VALUE "FileVersion", "4, 1, 2, 0\0" - VALUE "InternalName", "x2goplugin\0" - VALUE "LegalCopyright", "Copyright � 2010-2018 X2Go Project\0" - VALUE "MIMEType", "application/x2go\0" - VALUE "OriginalFilename", "npx2goplugin.dll\0" - VALUE "ProductName", "X2GoClient Plug-in 4.1.2.0\0" - VALUE "ProductVersion", "4, 1, 2, 0\0" - END - END - BLOCK "VarFileInfo" - BEGIN - VALUE "Translation", 0x409, 1252 - END -END -- Alioth's /home/x2go-admin/maintenancescripts/git/hooks/post-receive-email on /srv/git/code.x2go.org/x2goclient.git
This is an automated email from the git hooks/post-receive script. x2go pushed a commit to branch master in repository x2goclient. commit cb360e17606b290087a326e000f26e3cc9b0f3f5 Author: Mihai Moldovan <ionic@ionic.de> Date: Wed Mar 14 02:24:31 2018 +0100 provider/: remove. --- debian/changelog | 1 + provider/etc/x2goplugin-apache.conf | 15 ------------ provider/share/x2goplugin.html | 47 ------------------------------------- 3 files changed, 1 insertion(+), 62 deletions(-) diff --git a/debian/changelog b/debian/changelog index dfe23cc..20706ca 100644 --- a/debian/changelog +++ b/debian/changelog @@ -36,6 +36,7 @@ x2goclient (4.1.2.0-0x2go1) UNRELEASED; urgency=medium - Makefile: remove plugin references. - Makefile: remove x2goclient_*.qm files in clean rule. - x2gobrowserplugin-2.4_1/: remove. + - provider/: remove. * x2goclient.spec: - Remove plugin references. * debian/rules: diff --git a/provider/etc/x2goplugin-apache.conf b/provider/etc/x2goplugin-apache.conf deleted file mode 100644 index b5bcb82..0000000 --- a/provider/etc/x2goplugin-apache.conf +++ /dev/null @@ -1,15 +0,0 @@ -Alias /x2goplugin.html /usr/share/x2go/plugin/x2goplugin.html - -<Directory /usr/share/x2go/plugin> - <IfModule mod_authz_core.c> - # Apache 2.4 - Require local - </IfModule> - <IfModule !mod_authz_core.c> - # Apache 2.2 - Order Deny,Allow - Deny from all - Allow from 127.0.0.1 - Allow from ::1 - </IfModule> -</Directory> diff --git a/provider/share/x2goplugin.html b/provider/share/x2goplugin.html deleted file mode 100644 index 0c0f058..0000000 --- a/provider/share/x2goplugin.html +++ /dev/null @@ -1,47 +0,0 @@ -<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN"> -<html> - <head> - <title>X2Go Application Service</title> - </head> - <body onload="checkPlugin()"> - <div id="x2goplugin"> - <object - src="location" - type="application/x2go" - name="x2goplugin" - palette="background" - height="100%" - hspace="0" - vspace="0" - width="100%" - x2goconfig=" -session=X2Go-Demo-Session -server=localhost -user= -sshport=22 -command=XFCE -rootless=false -sound=true -exportfs=true -speed=adsl -compression=16m-jpeg -quality=9 -dpi=120 -kbdlayout= -kbdtype=auto -showtoolbar=true -showstatusbar=true -usekbd=true -soundsystem=pulse -soundtunnel=true -defsndport=true -print=true -rootless=false -published=false -applications=WWWBROWSER, MAILCLIENT, OFFICE, TERMINAL -"> - </object> - - </div> - </body> -</html> -- Alioth's /home/x2go-admin/maintenancescripts/git/hooks/post-receive-email on /srv/git/code.x2go.org/x2goclient.git
This is an automated email from the git hooks/post-receive script. x2go pushed a commit to branch master in repository x2goclient. commit bd2436fc41c6b328ad145c864e05be7678ecc7e5 Author: Mihai Moldovan <ionic@ionic.de> Date: Wed Mar 14 02:14:46 2018 +0100 debian/control: convert plugin packages to dummy transitional packages with no dependencies, remove other plugin references. --- debian/changelog | 3 +++ debian/control | 36 +++++++++++------------------------- 2 files changed, 14 insertions(+), 25 deletions(-) diff --git a/debian/changelog b/debian/changelog index 6ecdfe1..8124940 100644 --- a/debian/changelog +++ b/debian/changelog @@ -37,6 +37,9 @@ x2goclient (4.1.2.0-0x2go1) UNRELEASED; urgency=medium - Remove plugin references. * debian/rules: - Remove plugin references. + * debian/control: + - Convert plugin packages to dummy transitional packages with no + dependencies, remove other plugin references. -- X2Go Release Manager <git-admin@x2go.org> Thu, 15 Feb 2018 22:01:32 +0100 diff --git a/debian/control b/debian/control index 86d3e78..d2178a8 100644 --- a/debian/control +++ b/debian/control @@ -15,7 +15,6 @@ Build-Depends: libx11-dev, libxpm-dev, man2html-base | man2html, - apache2-dev | apache2-threaded-dev, Standards-Version: 3.9.5 Homepage: https://code.x2go.org/releases/source/x2goclient Vcs-Git: git://code.x2go.org/x2goclient.git @@ -51,18 +50,10 @@ Description: X2Go Client application (Qt4) You can use it to connect to running sessions and start new sessions. Package: x2goplugin -Architecture: any +Architecture: all Depends: - ${shlibs:Depends}, ${misc:Depends}, - openssh-client, - nxproxy, -Recommends: - openssh-server, - rdesktop | freerdp-x11, -Suggests: - pinentry-x2go, -Description: X2Go Client (Qt4) as browser plugin +Description: X2Go Client (Qt4) as browser plugin (dummy package) X2Go is a serverbased computing environment with - session resuming - low bandwidth support @@ -75,18 +66,14 @@ Description: X2Go Client (Qt4) as browser plugin X2Go Client is a graphical client (qt4) for the X2Go system. You can use it to connect to running sessions and start new sessions. . - This package provides X2Go Client as QtBrowser-based Mozilla plugin. + This package can be safely removed. Since X2Go Client 4.1.2.0, + the X2Go Plugin has been removed without a replacement. Package: x2goplugin-provider Architecture: all Depends: ${misc:Depends}, -Recommends: - ${misc:Recommends}, - httpd | apache2, -Suggests: - x2goplugin, -Description: Provide X2Go Plugin via Apache webserver +Description: Provide X2Go Plugin via Apache webserver (dummy package) X2Go is a serverbased computing environment with - session resuming - low bandwidth support @@ -96,8 +83,8 @@ Description: Provide X2Go Plugin via Apache webserver - audio support - authentication by smartcard and USB stick . - This package provides an example configuration for providing - the X2Go Plugin via an Apache webserver. + This package can be safely removed. Since X2Go Client 4.1.2.0, + the X2Go Plugin has been removed without a replacement. Package: x2goclient-dbg Section: debug @@ -122,11 +109,10 @@ Description: X2Go Client application (Qt4), debug symbols (client) Package: x2goplugin-dbg Section: debug -Architecture: any +Architecture: all Depends: ${misc:Depends}, - x2goplugin (= ${binary:Version}), -Description: X2Go Client application (Qt4), debug symbols (plugin) +Description: X2Go Client application (Qt4), debug symbols (plugin) (dummy package) X2Go is a serverbased computing environment with - session resuming - low bandwidth support @@ -139,5 +125,5 @@ Description: X2Go Client application (Qt4), debug symbols (plugin) X2Go Client is a graphical client (Qt4) for the X2Go system. You can use it to connect to running sessions and start new sessions . - This package provides the debug symbols for the QtBrowser-based Mozilla - X2Go Client plugin. + This package can be safely removed. Since X2Go Client 4.1.2.0, + the X2Go Plugin has been removed without a replacement. -- Alioth's /home/x2go-admin/maintenancescripts/git/hooks/post-receive-email on /srv/git/code.x2go.org/x2goclient.git
This is an automated email from the git hooks/post-receive script. x2go pushed a commit to branch master in repository x2goclient. commit 535ce5731f310866d11d00cbcfa84abe921669ff Author: Mihai Moldovan <ionic@ionic.de> Date: Wed Mar 14 02:28:27 2018 +0100 INSTALL: remove plugin references. --- INSTALL | 14 ++------------ debian/changelog | 1 + 2 files changed, 3 insertions(+), 12 deletions(-) diff --git a/INSTALL b/INSTALL index cd9412a..f81f32a 100644 --- a/INSTALL +++ b/INSTALL @@ -35,19 +35,11 @@ On Linux-based systems, run: make all -to build both X2Go Client and X2Go Plugin - or make build_client -to build X2Go Client only - -or - -make build_plugin - -to build X2Go Plugin only. +to build X2Go Client. Installing @@ -57,13 +49,11 @@ On Linux-based systems, run: make install -to install X2Go Client, X2Go Plugin, man pages and the plugin provider. +to install X2Go Client. Alternatively, use one of the targets: - install_client: for X2Go Client only - - install_plugin: for X2Go Plugin only - install_man: for the man pages only - - install_pluginprovider: for the plugin provider only Uninstalling diff --git a/debian/changelog b/debian/changelog index 20706ca..ccc9196 100644 --- a/debian/changelog +++ b/debian/changelog @@ -37,6 +37,7 @@ x2goclient (4.1.2.0-0x2go1) UNRELEASED; urgency=medium - Makefile: remove x2goclient_*.qm files in clean rule. - x2gobrowserplugin-2.4_1/: remove. - provider/: remove. + - INSTALL: remove plugin references. * x2goclient.spec: - Remove plugin references. * debian/rules: -- Alioth's /home/x2go-admin/maintenancescripts/git/hooks/post-receive-email on /srv/git/code.x2go.org/x2goclient.git
This is an automated email from the git hooks/post-receive script. x2go pushed a commit to branch master in repository x2goclient. commit 58a7ad448acd54defe80b073c06953e1b4d95ab5 Author: Mihai Moldovan <ionic@ionic.de> Date: Wed Mar 14 02:46:38 2018 +0100 debian/copyright: remove plugin references. --- debian/changelog | 2 ++ debian/copyright | 35 ----------------------------------- 2 files changed, 2 insertions(+), 35 deletions(-) diff --git a/debian/changelog b/debian/changelog index 0da22ef..b7ec4e5 100644 --- a/debian/changelog +++ b/debian/changelog @@ -53,6 +53,8 @@ x2goclient (4.1.2.0-0x2go1) UNRELEASED; urgency=medium - x2goplugin{,-provider}.install: clear out. - {x2goplugin.dirs,x2goplugin-provider.dirs,x2goplugin-provider.links, x2goplugin-provider.post*}: remove. + * debian/copyright: + - Remove plugin references. -- X2Go Release Manager <git-admin@x2go.org> Thu, 15 Feb 2018 22:01:32 +0100 diff --git a/debian/copyright b/debian/copyright index a48bb40..1d24640 100644 --- a/debian/copyright +++ b/debian/copyright @@ -44,41 +44,6 @@ Comment: * version. If you delete this exception statement from all source * files in the program, then also delete it here. -Files: x2gobrowserplugin-2.4_1/src/* -Copyright: 2009, Nokia Corporation and/or its subsidiary(-ies). -License: BSD-3-clause - Contact: Nokia Corporation (qt-info@nokia.com) - . - This file is part of a Qt Solutions component. - . - You may use this file under the terms of the BSD license as follows: - . - "Redistribution and use in source and binary forms, with or without - modification, are permitted provided that the following conditions are - met: - * Redistributions of source code must retain the above copyright - notice, this list of conditions and the following disclaimer. - * Redistributions in binary form must reproduce the above copyright - notice, this list of conditions and the following disclaimer in - the documentation and/or other materials provided with the - distribution. - * Neither the name of Nokia Corporation and its Subsidiary(-ies) nor - the names of its contributors may be used to endorse or promote - products derived from this software without specific prior written - permission. - . - THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS - "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT - LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR - A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT - OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, - SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT - LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, - DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY - THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT - (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE - OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE." - Files: Makefile.docupload Copyright: 2010-2017, Mike Gabriel <mike.gabriel@das-netzwerkteam.de> License: GPL-3 -- Alioth's /home/x2go-admin/maintenancescripts/git/hooks/post-receive-email on /srv/git/code.x2go.org/x2goclient.git
This is an automated email from the git hooks/post-receive script. x2go pushed a commit to branch master in repository x2goclient. commit 53f656a9f1fc1fa18d9c90cb2cae6678d3d6d5ea Author: Mihai Moldovan <ionic@ionic.de> Date: Wed Mar 14 02:30:30 2018 +0100 debian/x2goplugin{,-provider}.install: clear out. --- debian/changelog | 2 ++ debian/x2goplugin-provider.install | 2 -- debian/x2goplugin.install | 1 - 3 files changed, 2 insertions(+), 3 deletions(-) diff --git a/debian/changelog b/debian/changelog index ccc9196..818b336 100644 --- a/debian/changelog +++ b/debian/changelog @@ -46,6 +46,8 @@ x2goclient (4.1.2.0-0x2go1) UNRELEASED; urgency=medium * debian/control: - Convert plugin packages to dummy transitional packages with no dependencies, remove other plugin references. + * debian/: + - x2goplugin{,-provider}.install: clear out. -- X2Go Release Manager <git-admin@x2go.org> Thu, 15 Feb 2018 22:01:32 +0100 diff --git a/debian/x2goplugin-provider.install b/debian/x2goplugin-provider.install index 8e79131..e69de29 100644 --- a/debian/x2goplugin-provider.install +++ b/debian/x2goplugin-provider.install @@ -1,2 +0,0 @@ -provider/etc/x2goplugin-apache.conf etc/x2go/ -provider/share/x2goplugin.html etc/x2go/plugin-provider/ diff --git a/debian/x2goplugin.install b/debian/x2goplugin.install index a3141b5..e69de29 100644 --- a/debian/x2goplugin.install +++ b/debian/x2goplugin.install @@ -1 +0,0 @@ -plugin_build/libx2goplugin.so usr/lib/mozilla/plugins/ -- Alioth's /home/x2go-admin/maintenancescripts/git/hooks/post-receive-email on /srv/git/code.x2go.org/x2goclient.git
This is an automated email from the git hooks/post-receive script. x2go pushed a commit to branch master in repository x2goclient. commit 51738fb489213ca28437e3959c6814fcfd9591d2 Author: Mihai Moldovan <ionic@ionic.de> Date: Wed Mar 14 02:32:38 2018 +0100 debian/{x2goplugin.dirs,x2goplugin-provider.dirs,x2goplugin-provider.links,x2goplugin-provider.post*}: remove. --- debian/changelog | 2 ++ debian/x2goplugin-provider.dirs | 2 -- debian/x2goplugin-provider.links | 2 -- debian/x2goplugin-provider.postinst | 49 ------------------------------------- debian/x2goplugin-provider.postrm | 47 ----------------------------------- debian/x2goplugin.dirs | 1 - 6 files changed, 2 insertions(+), 101 deletions(-) diff --git a/debian/changelog b/debian/changelog index 818b336..9670914 100644 --- a/debian/changelog +++ b/debian/changelog @@ -48,6 +48,8 @@ x2goclient (4.1.2.0-0x2go1) UNRELEASED; urgency=medium dependencies, remove other plugin references. * debian/: - x2goplugin{,-provider}.install: clear out. + - {x2goplugin.dirs,x2goplugin-provider.dirs,x2goplugin-provider.links, + x2goplugin-provider.post*}: remove. -- X2Go Release Manager <git-admin@x2go.org> Thu, 15 Feb 2018 22:01:32 +0100 diff --git a/debian/x2goplugin-provider.dirs b/debian/x2goplugin-provider.dirs deleted file mode 100644 index b8f6dbe..0000000 --- a/debian/x2goplugin-provider.dirs +++ /dev/null @@ -1,2 +0,0 @@ -etc/x2go/plugin-provider -etc/apache2/conf.d diff --git a/debian/x2goplugin-provider.links b/debian/x2goplugin-provider.links deleted file mode 100644 index c1af701..0000000 --- a/debian/x2goplugin-provider.links +++ /dev/null @@ -1,2 +0,0 @@ -etc/x2go/x2goplugin-apache.conf etc/apache2/conf-available/x2goplugin-provider.conf -etc/x2go/plugin-provider/x2goplugin.html usr/share/x2go/plugin/x2goplugin.html diff --git a/debian/x2goplugin-provider.postinst b/debian/x2goplugin-provider.postinst deleted file mode 100755 index 0808138..0000000 --- a/debian/x2goplugin-provider.postinst +++ /dev/null @@ -1,49 +0,0 @@ -#!/bin/sh -# postinst script for x2goplugin-provider -# -# see: dh_installdeb(1) - -set -e - -# summary of how this script can be called: -# * <postinst> `configure' <most-recently-configured-version> -# * <old-postinst> `abort-upgrade' <new version> -# * <conflictor's-postinst> `abort-remove' `in-favour' <package> -# <new-version> -# * <postinst> `abort-remove' -# * <deconfigured's-postinst> `abort-deconfigure' `in-favour' -# <failed-install-package> <version> `removing' -# <conflicting-package> <version> -# for details, see http://www.debian.org/doc/debian-policy/ or -# the debian-policy package - - -case "$1" in - configure) - CONF="x2goplugin-provider" - COMMON_STATE=$(dpkg-query -f '${Status}' -W 'apache2.2-common' 2>/dev/null | awk '{print $3}' || true) - - if [ -e /usr/share/apache2/apache2-maintscript-helper ] ; then - . /usr/share/apache2/apache2-maintscript-helper - apache2_invoke enconf $CONF || exit $? - elif [ "$COMMON_STATE" = "installed" ] || [ "$COMMON_STATE" = "unpacked" ] ; then - [ -d /etc/apache2/conf.d/ ] && [ ! -L /etc/apache2/conf.d/$CONF.conf ] && ln -s ../conf-available/$CONF.conf /etc/apache2/conf.d/$CONF.conf - fi - ;; - - abort-upgrade|abort-remove|abort-deconfigure) - ;; - - *) - echo "postinst called with unknown argument \`$1'" >&2 - exit 1 - ;; - -esac - -# dh_installdeb will replace this with shell code automatically -# generated by other debhelper scripts. - -#DEBHELPER# - -exit 0 diff --git a/debian/x2goplugin-provider.postrm b/debian/x2goplugin-provider.postrm deleted file mode 100755 index 74b1218..0000000 --- a/debian/x2goplugin-provider.postrm +++ /dev/null @@ -1,47 +0,0 @@ -#! /bin/sh -# postrm script for x2goplugin-provider -# -# see: dh_installdeb(1) - -set -e - -# summary of how this script can be called: -# * <postrm> `remove' -# * <postrm> `purge' -# * <old-postrm> `upgrade' <new-version> -# * <new-postrm> `failed-upgrade' <old-version> -# * <new-postrm> `abort-install' -# * <new-postrm> `abort-install' <old-version> -# * <new-postrm> `abort-upgrade' <old-version> -# * <disappearer's-postrm> `disappear' <r>overwrit>r> <new-version> -# for details, see /usr/share/doc/packaging-manual/ - -case "$1" in - remove|purge) - CONF="x2goplugin-provider" - COMMON_STATE=$(dpkg-query -f '${Status}' -W 'apache2.2-common' 2>/dev/null | awk '{print $3}' || true) - - if [ -e /usr/share/apache2/apache2-maintscript-helper ] ; then - . /usr/share/apache2/apache2-maintscript-helper - apache2_invoke disconf $CONF || exit $? - elif [ "$COMMON_STATE" = "installed" ] || [ "$COMMON_STATE" = "unpacked" ] ; then - [ ! -L /etc/apache2/conf.d/$CONF.conf ] || rm /etc/apache2/conf.d/$CONF.conf - fi - ;; - - upgrade|failed-upgrade|abort-install|abort-upgrade|disappear) - ;; - - *) - echo "postrm called with unknown argument \`$1'" >&2 - exit 0 - ;; - -esac - -# dh_installdeb will replace this with shell code automatically -# generated by other debhelper scripts. - -#DEBHELPER# - -exit 0 \ No newline at end of file diff --git a/debian/x2goplugin.dirs b/debian/x2goplugin.dirs deleted file mode 100644 index 2d4917c..0000000 --- a/debian/x2goplugin.dirs +++ /dev/null @@ -1 +0,0 @@ -usr/lib/mozilla/plugins/ -- Alioth's /home/x2go-admin/maintenancescripts/git/hooks/post-receive-email on /srv/git/code.x2go.org/x2goclient.git
This is an automated email from the git hooks/post-receive script. x2go pushed a commit to branch master in repository x2goclient. commit 1374ac4f62ecb73ad3ffa6a239bd097a6469eb86 Author: Mihai Moldovan <ionic@ionic.de> Date: Wed Mar 14 02:36:18 2018 +0100 {{build,config}_win_plugin.bat,config_linux_{,static_}plugin.sh}: remove. --- build_win_plugin.bat | 17 ----------------- config_linux_plugin.sh | 7 ------- config_linux_static_plugin.sh | 8 -------- config_win_plugin.bat | 8 -------- debian/changelog | 2 ++ 5 files changed, 2 insertions(+), 40 deletions(-) diff --git a/build_win_plugin.bat b/build_win_plugin.bat deleted file mode 100755 index 4da4823..0000000 --- a/build_win_plugin.bat +++ /dev/null @@ -1,17 +0,0 @@ -cd plugin_build - -mingw32-make - -copy release\npx2goplugin.dll d:\share\plugin\x2goplugin\ - -d: - -cd share\plugin\x2goplugin\ - -idc.exe npx2goplugin.dll /idl npx2goplugin.idl -version 1.0 - -midl npx2goplugin.idl /nologo /tlb npx2goplugin.tlb - -idc.exe npx2goplugin.dll /tlb npx2goplugin.tlb - -cd .. diff --git a/config_linux_plugin.sh b/config_linux_plugin.sh deleted file mode 100755 index d33a481..0000000 --- a/config_linux_plugin.sh +++ /dev/null @@ -1,7 +0,0 @@ -#!/bin/bash - -make distclean - -lrelease x2goclient.pro - -X2GO_CLIENT_TARGET=plugin qmake-qt4 diff --git a/config_linux_static_plugin.sh b/config_linux_static_plugin.sh deleted file mode 100755 index f5efaf2..0000000 --- a/config_linux_static_plugin.sh +++ /dev/null @@ -1,8 +0,0 @@ -#!/bin/bash - -make distclean - -lrelease x2goclient.pro - -export X2GO_LINUX_STATIC=x2go_linux_static -X2GO_CLIENT_TARGET=plugin /usr/local/Trolltech/Qt-4.8.5/bin/qmake -config release -spec linux-g++ diff --git a/config_win_plugin.bat b/config_win_plugin.bat deleted file mode 100755 index 5541764..0000000 --- a/config_win_plugin.bat +++ /dev/null @@ -1,8 +0,0 @@ -rmdir /s /q plugin_build - -mkdir plugin_build - -set X2GO_CLIENT_TARGET=plugin -qmake ..\x2goclient.pro - -cd .. diff --git a/debian/changelog b/debian/changelog index 9670914..a0fd362 100644 --- a/debian/changelog +++ b/debian/changelog @@ -38,6 +38,8 @@ x2goclient (4.1.2.0-0x2go1) UNRELEASED; urgency=medium - x2gobrowserplugin-2.4_1/: remove. - provider/: remove. - INSTALL: remove plugin references. + - {{build,config}_win_plugin.bat,config_linux_{,static_}plugin.sh}: + remove. * x2goclient.spec: - Remove plugin references. * debian/rules: -- Alioth's /home/x2go-admin/maintenancescripts/git/hooks/post-receive-email on /srv/git/code.x2go.org/x2goclient.git
This is an automated email from the git hooks/post-receive script. x2go pushed a commit to branch master in repository x2goclient. commit e7d4e13abe947883c0bffc556b1c3a2e2928c50e Author: Mihai Moldovan <ionic@ionic.de> Date: Wed Mar 14 02:44:33 2018 +0100 config_win.bat: remove plugin references. --- config_win.bat | 1 - debian/changelog | 1 + 2 files changed, 1 insertion(+), 1 deletion(-) diff --git a/config_win.bat b/config_win.bat index c54f305..43e6bd6 100755 --- a/config_win.bat +++ b/config_win.bat @@ -1,5 +1,4 @@ rmdir /s /q client_build -rmdir /s /q plugin_build mingw32-make clean diff --git a/debian/changelog b/debian/changelog index a0fd362..0da22ef 100644 --- a/debian/changelog +++ b/debian/changelog @@ -40,6 +40,7 @@ x2goclient (4.1.2.0-0x2go1) UNRELEASED; urgency=medium - INSTALL: remove plugin references. - {{build,config}_win_plugin.bat,config_linux_{,static_}plugin.sh}: remove. + - config_win.bat: remove plugin references. * x2goclient.spec: - Remove plugin references. * debian/rules: -- Alioth's /home/x2go-admin/maintenancescripts/git/hooks/post-receive-email on /srv/git/code.x2go.org/x2goclient.git
This is an automated email from the git hooks/post-receive script. x2go pushed a commit to branch master in repository x2goclient. commit 83b8a9c14c6fd92f924a12ab2316f242ff76cd13 Author: Mihai Moldovan <ionic@ionic.de> Date: Wed Mar 14 03:04:40 2018 +0100 src/{configdialog.cpp,onmainwindow{.cpp,{,_privat}.h}}: remove plugin references. --- debian/changelog | 2 + src/configdialog.cpp | 8 - src/onmainwindow.cpp | 411 +--------------------------------------------- src/onmainwindow.h | 77 --------- src/onmainwindow_privat.h | 7 - 5 files changed, 4 insertions(+), 501 deletions(-) diff --git a/debian/changelog b/debian/changelog index b7ec4e5..53fde6a 100644 --- a/debian/changelog +++ b/debian/changelog @@ -41,6 +41,8 @@ x2goclient (4.1.2.0-0x2go1) UNRELEASED; urgency=medium - {{build,config}_win_plugin.bat,config_linux_{,static_}plugin.sh}: remove. - config_win.bat: remove plugin references. + - src/{configdialog.cpp,onmainwindow{.cpp,{,_privat}.h}}: remove plugin + references. * x2goclient.spec: - Remove plugin references. * debian/rules: diff --git a/src/configdialog.cpp b/src/configdialog.cpp index 565333a..7651920 100644 --- a/src/configdialog.cpp +++ b/src/configdialog.cpp @@ -62,9 +62,6 @@ ConfigDialog::ConfigDialog ( QWidget * parent, Qt::WindowFlags f ) X2goSettings st ( "settings" ); - -#ifndef CFGPLUGIN - gbTrayIcon=new QGroupBox(tr("Display icon in system tray"),fr); frLay->addWidget(gbTrayIcon); gbTrayIcon->setCheckable(true); @@ -86,7 +83,6 @@ ConfigDialog::ConfigDialog ( QWidget * parent, Qt::WindowFlags f ) cbMaxmizeTray->setChecked ( st.setting()->value ( "trayicon/maxdiscon", false ).toBool() ); cbNoClose->setChecked ( st.setting()->value ( "trayicon/noclose", false ).toBool() ); cbMinToTray->setChecked ( st.setting()->value ( "trayicon/mintotray", false ).toBool() ); -#endif #ifdef USELDAP if ( !embedMode ) @@ -373,13 +369,11 @@ ConfigDialog::~ConfigDialog() void ConfigDialog::slot_accepted() { X2goSettings st ( "settings" ); -#ifndef CFGPLUGIN st.setting()->setValue ( "trayicon/enabled", gbTrayIcon->isChecked() ); st.setting()->setValue ( "trayicon/mintotray", cbMinToTray->isChecked() ); st.setting()->setValue ( "trayicon/noclose", cbNoClose->isChecked() ); st.setting()->setValue ( "trayicon/mincon", cbMinimizeTray->isChecked() ); st.setting()->setValue ( "trayicon/maxdiscon", cbMaxmizeTray->isChecked() ); -#endif #if defined (Q_OS_WIN) || defined (Q_OS_DARWIN) if(!systemDisablePARecord) st.setting()->setValue ( "pulse/norecord", cbNoRecord->isChecked() ); @@ -684,13 +678,11 @@ void ConfigDialog::slotDefaults() cbNoRecord->setChecked (false); cbDisablePA->setChecked (false); #endif /* defined (Q_OS_DARWIN) */ -#ifndef CFGPLUGIN gbTrayIcon->setChecked (false); cbMinimizeTray->setChecked (false); cbMaxmizeTray->setChecked ( false); cbNoClose->setChecked (false); cbMinToTray->setChecked (false); -#endif } break; #if defined (Q_OS_WIN) && defined (CFGCLIENT) diff --git a/src/onmainwindow.cpp b/src/onmainwindow.cpp index f3341c9..61641ff 100644 --- a/src/onmainwindow.cpp +++ b/src/onmainwindow.cpp @@ -166,16 +166,6 @@ ONMainWindow::ONMainWindow ( QWidget *parent ) :QMainWindow ( parent ) appDir=QApplication::applicationDirPath(); -#if defined Q_OS_WIN && defined CFGPLUGIN - wchar_t pluginpath[1024]; - HMODULE module; - module=GetModuleHandleW ( L"npx2goplugin.dll" ); - GetModuleFileNameW ( module,pluginpath, 1024 ); - QString ppstr=QString::fromUtf16 ( ( const ushort* ) pluginpath ); - ppstr.replace ( "\\npx2goplugin.dll","" ); - appDir=wapiShortFileName ( ppstr ); - QDir::setCurrent ( appDir ); -#endif homeDir=QDir::homePath(); #ifdef Q_OS_WIN @@ -261,11 +251,6 @@ ONMainWindow::ONMainWindow ( QWidget *parent ) :QMainWindow ( parent ) } #endif -#ifdef CFGPLUGIN - embedMode=true; -#endif - - //set homedir as portable,etc @@ -476,12 +461,6 @@ ONMainWindow::ONMainWindow ( QWidget *parent ) :QMainWindow ( parent ) connect(interDlg, SIGNAL(closeInterractionDialog()), this, SLOT(slotCloseInteractionDialog())); username->addWidget ( interDlg ); -#if defined(CFGPLUGIN) && defined(Q_OS_LINUX) - - x2goDebug<<"Creating embedded container."; - embedContainer=new QX11EmbedContainer ( fr ); - -#endif if ( !embedMode ) { initWidgetsNormal(); @@ -740,141 +719,6 @@ void ONMainWindow::installTranslator () { void ONMainWindow::initWidgetsEmbed() { -#ifdef CFGPLUGIN - doPluginInit(); - stb=new QToolBar ( this ); - addToolBar ( stb ); - stb->toggleViewAction()->setEnabled ( false ); - stb->toggleViewAction()->setVisible ( false ); - stb->setFloatable ( false ); - stb->setMovable ( false ); - statusBar()->setSizeGripEnabled ( false ); -#ifndef Q_OS_WIN - statusBar()->hide(); -#endif - - - act_shareFolder=new QAction ( QIcon ( ":/img/icons/32x32/file-open.png" ), - tr ( "Share folder..." ),this ); - - act_showApps=new QAction ( QIcon ( ":/img/icons/32x32/apps.png" ), - tr ( "Applications..." ),this ); - - act_suspend=new QAction ( QIcon ( ":/img/icons/32x32/suspend.png" ), - tr ( "Suspend" ),this ); - - act_terminate=new QAction ( QIcon ( ":/img/icons/32x32/stop.png" ), - tr ( "Terminate" ),this ); - act_reconnect=new QAction ( QIcon ( ":/img/icons/32x32/reconnect.png" ), - tr ( "Reconnect" ),this ); - act_reconnect->setEnabled ( false ); - - act_embedContol=new QAction ( QIcon ( ":/img/icons/32x32/detach.png" ), - tr ( "Detach X2Go window" ),this ); - - act_embedToolBar=new QAction ( QIcon ( ":/img/icons/32x32/tbhide.png" ), - tr ( "Minimize toolbar" ),this ); - - - setEmbedSessionActionsEnabled ( false ); - - connect ( act_shareFolder,SIGNAL ( triggered ( bool ) ),this, - SLOT ( slotExportDirectory() ) ); - - connect ( act_showApps,SIGNAL ( triggered ( bool ) ),this, - SLOT ( slotAppDialog() ) ); - - connect ( act_suspend,SIGNAL ( triggered ( bool ) ),this, - SLOT ( slotSuspendSessFromSt() ) ); - - connect ( act_terminate,SIGNAL ( triggered ( bool ) ),this, - SLOT ( slotTermSessFromSt() ) ); - - connect ( act_reconnect,SIGNAL ( triggered ( bool ) ),this, - SLOT ( slotReconnectSession() ) ); - - connect ( act_embedContol,SIGNAL ( triggered ( bool ) ),this, - SLOT ( slotEmbedControlAction() ) ); - - connect ( act_embedToolBar,SIGNAL ( triggered ( bool ) ),this, - SLOT ( slotEmbedToolBar() ) ); - - - - processSessionConfig(); - -////embed container//////// -#ifndef Q_OS_DARWIN - - oldParentSize=QSize ( 0,0 ); - -#ifdef Q_OS_WIN - oldParentPos=QPoint ( 0,0 ); -#endif - childId=0l; -#ifdef Q_OS_LINUX - - connect ( embedContainer, SIGNAL ( clientClosed() ), this, - SLOT ( slotDetachProxyWindow() ) ); - - - embedContainer->connect ( embedContainer, SIGNAL ( clientClosed() ), - embedContainer, SLOT ( hide() ) ); -#endif -#ifdef Q_OS_WIN - embedContainer=new QWidget ( mainWidget() ); - - updateTimer = new QTimer ( this ); - connect ( updateTimer, SIGNAL ( timeout() ), this, - SLOT ( slotUpdateEmbedWindow() ) ); -#endif - embedContainer->hide(); - mainLayout()->addWidget ( embedContainer ); -#endif -//end of embed container - - X2goSettings st ( "sessions" ); - - embedTbVisible=!st.setting()->value ( - "embedded/tbvisible", true ).toBool(); - - slotEmbedToolBar(); - - - showTbTooltip=false; - if ( !embedTbVisible ) - { - showTbTooltip=true; - QTimer::singleShot ( 500, this, - SLOT ( slotEmbedToolBarToolTip() ) ); - QTimer::singleShot ( 3000, this, - SLOT ( slotHideEmbedToolBarToolTip() ) ); - } - if ( !config.showtoolbar ) - { - stb->hide(); - } - if ( config.confFS&& ( !config.useFs ) ) - { - x2goDebug<<"hide share"; - - act_shareFolder->setVisible ( false ); - } - - act_showApps->setVisible(false); - - - if ( !managedMode ) - { - -#ifdef Q_OS_LINUX - QTimer::singleShot ( 500, this, - SLOT ( slotActivateWindow() ) ); -#endif - - } -#endif//CFGPLUGIN - } void ONMainWindow::initWidgetsNormal() @@ -1215,8 +1059,6 @@ void ONMainWindow::slotGetBrokerAuth() void ONMainWindow::trayIconInit() { - -#ifndef CFGPLUGIN X2goSettings st ( "settings" ); trayEnabled=st.setting()->value ( "trayicon/enabled", false ).toBool(); trayMinCon=st.setting()->value ( "trayicon/mincon", false ).toBool(); @@ -1317,7 +1159,6 @@ void ONMainWindow::trayIconInit() plugAppsInTray(); } } -#endif } QMenu* ONMainWindow::initTrayAppMenu(QString text, QPixmap icon) @@ -6258,12 +6099,6 @@ void ONMainWindow::slotProxyFinished ( int,QProcess::ExitStatus ) if ( embedMode ) { - if ( proxyWinEmbedded ) - { -#ifdef CFGPLUGIN - detachClient(); -#endif - } proxyWinTimer->stop(); setEmbedSessionActionsEnabled ( false ); } @@ -6301,7 +6136,6 @@ void ONMainWindow::slotProxyFinished ( int,QProcess::ExitStatus ) disconnect ( nxproxy,SIGNAL ( readyReadStandardOutput() ),this, SLOT ( slotProxyStdout() ) ); proxyRunning=false; -#ifndef CFGPLUGIN if (trayEnabled) { trayIconActiveConnectionMenu->setTitle(tr("Not connected")); @@ -6310,7 +6144,6 @@ void ONMainWindow::slotProxyFinished ( int,QProcess::ExitStatus ) showNormal(); } trayAutoHidden=false; -#endif bool emergencyExit=false; if(proxyErrString.indexOf("No data received from remote proxy")!=-1) @@ -6319,7 +6152,6 @@ void ONMainWindow::slotProxyFinished ( int,QProcess::ExitStatus ) x2goWarningf(4)<< tr( "Emergency exit." ); } -#if ! (defined (CFGPLUGIN)) if ( nxproxy ) { if ( nxproxy->state() ==QProcess::Running ) @@ -6338,7 +6170,6 @@ void ONMainWindow::slotProxyFinished ( int,QProcess::ExitStatus ) nxproxy=0; #endif } -#endif x2goDebug<<"Waiting for proxy to exit."; spoolTimer=0l; @@ -6473,7 +6304,6 @@ void ONMainWindow::slotProxyStderr() "Established X server connection" ) !=-1 ) { setStatStatus ( tr ( "running" ) ); -#ifndef CFGPLUGIN if (trayEnabled) { if (!useLdap) @@ -6487,7 +6317,6 @@ void ONMainWindow::slotProxyStderr() hide(); } } -#endif if ( embedMode ) setEmbedSessionActionsEnabled ( true ); disconnect ( sbSusp,SIGNAL ( clicked() ),this, @@ -6539,17 +6368,6 @@ void ONMainWindow::slotProxyStderr() if ( stInfo->toPlainText().indexOf ( tr ( "Connection timeout, aborting" ) ) !=-1 ) setStatStatus ( tr ( "aborting" ) ); -#if defined( Q_OS_WIN ) && defined (CFGPLUGIN) - if ( reserr.indexOf ( "Session terminated at" ) !=-1 ) - { - - x2goDebug<<"Proxy finished."; - - slotProxyFinished ( 0, QProcess::NormalExit ); - } -#endif - - } @@ -6783,9 +6601,7 @@ void ONMainWindow::setStatStatus ( QString status ) if ( !embedMode || !proxyWinEmbedded ) { statusBar()->showMessage ( ""); -#if ! (defined Q_OS_WIN && defined CFGPLUGIN) statusBar()->hide(); -#endif QString srv; if ( brokerMode ) { @@ -6831,13 +6647,11 @@ void ONMainWindow::setStatStatus ( QString status ) tr ( "Display" ) +": "+ resumingSession.display+", "+ tr ( "Creation time" ) +": "+tstr; -#if ! (defined Q_OS_WIN && defined CFGPLUGIN) if ( statusLabel ) { statusLabel->setText ( " "+message ); } else -#endif { if ( config.showstatusbar ) { @@ -8890,10 +8704,6 @@ void ONMainWindow::slotAbout() { QString aboutStr=tr ("<br>(C) 2005-2017 by <b>obviously nice</b>: " "Oleksandr Shneyder, Heinz-Markus Graesing<br>" ); - if ( embedMode ) - aboutStr+=tr ( "<br>X2Go Plugin mode was sponsored by " - "<a href=\"http://www.foss-group.de/\">" - "FOSS-Group GmbH (Freiburg)</a><br>" ); aboutStr+= tr ( "<br>This is a client to access the X2Go network-based " @@ -11433,9 +11243,6 @@ void ONMainWindow::slotAttachProxyWindow() void ONMainWindow::slotEmbedWindow() { #ifndef Q_OS_DARWIN -#ifdef CFGPLUGIN - embedWindow ( proxyWinId ); -#endif QTimer::singleShot ( 1000, this, SLOT ( slotActivateWindow() ) ); @@ -11457,14 +11264,10 @@ void ONMainWindow::slotEmbedControlAction() { #ifndef Q_OS_DARWIN embedControlChanged=true; - if ( proxyWinEmbedded ) + if ( !proxyWinEmbedded ) { -#ifdef CFGPLUGIN - detachClient(); -#endif - } - else slotAttachProxyWindow(); + } #endif } @@ -12905,213 +12708,3 @@ void ONMainWindow::slotInitLibssh () { trayQuit (); } } - -//////////////////////////plugin stuff////////////// - -#ifdef CFGPLUGIN -void ONMainWindow::setX2goconfig ( const QString& text ) -{ - m_x2goconfig=text; - - x2goDebug<<"Having a session config."; - - initWidgetsEmbed(); -} - -void ONMainWindow::doPluginInit() -{ -#ifdef Q_OS_LINUX - Dl_info info; - dladdr ( ( void* ) & ( ONMainWindow::getPortable ),&info ); - QString fname=info.dli_fname; - - x2goDebug<<"Application name:" <<fname; - - QString clientDir; - QString pluginDir; - int pos=fname.lastIndexOf ( "/" ); - pluginDir=fname.left ( pos ); - - x2goDebug<<"Plugin directory: " <<pluginDir; - - QDir dr ( pluginDir ); - if ( dr.exists ( "x2goclient/x2goclient" ) ) - { - clientDir=pluginDir+"/x2goclient"; - } - else if ( dr.exists ( "x2goclient" ) ) - { - clientDir=pluginDir; - } - else - { - dr.cdUp(); - if ( dr.exists ( "x2goclient/x2goclient" ) ) - { - clientDir=dr.absolutePath() +"/x2goclient"; - } - else if ( dr.exists ( "x2goclient" ) ) - { - clientDir=dr.absolutePath(); - } - else - { - clientDir=pluginDir; - } - } - - x2goDebug<<"Client directory: "<<clientDir; - - QString path=getenv ( "PATH" ); - path=clientDir+":"+pluginDir+":"+path; - setenv ( "PATH",path.toLatin1 (),1 ); - - path=getenv ( "LD_LIBRARY_PATH" ); - path=clientDir+":"+pluginDir+":"+path; - setenv ( "LD_LIBRARY_PATH",path.toLatin1 () ,1 ); - - setenv ( "X2GO_LIB",clientDir.toLatin1 () ,1 ); - - QFile::setPermissions ( - clientDir+"/x2goclient", - QFile::ReadOwner|QFile::WriteOwner|QFile::ExeOwner| - QFile::ReadGroup|QFile::WriteGroup|QFile::ExeGroup| - QFile::ReadOther|QFile::WriteOther|QFile::ExeOther ); - QFile::setPermissions ( - clientDir+"/nxproxy", - QFile::ReadOwner|QFile::WriteOwner|QFile::ExeOwner| - QFile::ReadGroup|QFile::WriteGroup|QFile::ExeGroup| - QFile::ReadOther|QFile::WriteOther|QFile::ExeOther ); - QFile::setPermissions ( - clientDir+"/sshd", - QFile::ReadOwner|QFile::WriteOwner|QFile::ExeOwner| - QFile::ReadGroup|QFile::WriteGroup|QFile::ExeGroup| - QFile::ReadOther|QFile::WriteOther|QFile::ExeOther ); - QFile::setPermissions ( - clientDir+"/sftp-server", - QFile::ReadOwner|QFile::WriteOwner|QFile::ExeOwner| - QFile::ReadGroup|QFile::WriteGroup|QFile::ExeGroup| - QFile::ReadOther|QFile::WriteOther|QFile::ExeOther ); - -#endif -} - - -#ifndef Q_OS_DARWIN - - -QSize ONMainWindow::getWindowSize ( long winId ) -{ - -#ifdef Q_OS_LINUX - XWindowAttributes atr; - if ( XGetWindowAttributes ( QX11Info::display(),winId,&atr ) ) - return QSize ( atr.width,atr.height ); - return QSize ( 0,0 ); -#endif -#ifdef Q_OS_WIN - QRect rec; - if ( wapiClientRect ( ( HWND ) winId,rec ) ) - return rec.size(); - else - return QSize ( 0,0 ); -#endif -} - -#ifdef Q_OS_WIN -void ONMainWindow::slotUpdateEmbedWindow() -{ - if ( oldContainerSize!=embedContainer->size() || - oldChildPos!= mapToGlobal ( - QPoint ( 0,0 ) ) ) - { - QRect geom=embedContainer->geometry(); - if ( gcor==1 ) - gcor=0; - else - gcor=1; - geom.setWidth ( geom.width()-gcor ); - wapiSetFSWindow ( ( HWND ) childId, - geom ); - wapiUpdateWindow ( ( HWND ) childId ); - oldContainerSize=embedContainer->size(); - oldChildPos= mapToGlobal ( - QPoint ( 0,0 ) ); - - x2goDebug<<"Updating embedded window."; - - } -} - -#endif - - - -void ONMainWindow::embedWindow ( long wndId ) -{ - childId=wndId; - embedContainer->show(); -#ifdef Q_OS_LINUX - - x2goDebug<<"Embedding window with ID "<<wndId<<" in container."; - - embedContainer->embedClient ( wndId ); -#endif -#ifdef Q_OS_WIN - wapiSetParent ( ( HWND ) childId, - ( HWND ) ( embedContainer->winId() ) ); - oldContainerSize=embedContainer->size(); - oldChildPos= ( mapToGlobal ( QPoint ( 0,0 ) )); - winFlags=wapiSetFSWindow ( ( HWND ) childId, - embedContainer->geometry() ); - updateTimer->start ( 500 ); - -#endif -} - - -void ONMainWindow::detachClient() -{ - if ( !childId ) - return; -#ifdef Q_OS_LINUX - if ( embedContainer ) - { - embedContainer->discardClient(); - } -#endif -#ifdef Q_OS_WIN - wapiSetParent ( ( HWND ) childId, ( HWND ) 0 ); - slotDetachProxyWindow(); - updateTimer->stop(); - if ( childId ) - { - wapiRestoreWindow ( ( HWND ) childId, winFlags, - embedContainer->geometry() ); - wapiMoveWindow ( ( HWND ) childId,0,0, - oldContainerSize.width(), - oldContainerSize.height(),true ); - - } -#endif - childId=0; -} - -#endif //(Q_OS_DARWIN) - - - - - -QTNPFACTORY_BEGIN ( "X2Go Client Plug-in "VERSION, - "Allows you to start X2Go sessions in a web browser." ) -QTNPCLASS ( ONMainWindow ) -QTNPFACTORY_END() - -#ifdef QAXSERVER -#include <ActiveQt/QAxFactory> -QAXFACTORY_BEGIN ( "{aa3216bf-7e20-482c-84c6-06167bacb616}", "{08538ca5-eb7a-4f24-a3c4-a120c6e04dc4}" ) -QAXCLASS ( ONMainWindow ) -QAXFACTORY_END() -#endif -#endif diff --git a/src/onmainwindow.h b/src/onmainwindow.h index 816dbd8..7272e66 100644 --- a/src/onmainwindow.h +++ b/src/onmainwindow.h @@ -18,18 +18,6 @@ #ifndef ONMAINWINDOW_H #define ONMAINWINDOW_H -#ifdef CFGPLUGIN -#include <QMetaClassInfo> -#include <qtbrowserplugin.h> - -#ifdef QAXSERVER -#include <ActiveQt/QAxBindable> -#include <ActiveQt/QAxFactory> -#include <qt_windows.h> -#endif - -#endif - #include "x2goclientconfig.h" //#include "CallbackInterface.h" #include <QMainWindow> @@ -65,9 +53,6 @@ @author Oleksandr Shneyder */ -#if defined(CFGPLUGIN) && defined(Q_OS_LINUX) -class QX11EmbedContainer; -#endif class QToolButton; class QTemporaryFile; class QLineEdit; @@ -266,27 +251,9 @@ Q_SIGNALS: class ClickLineEdit; class ONMainWindow : public QMainWindow -#ifdef CFGPLUGIN - , public QtNPBindable - -#ifdef QAXSERVER - , public QAxBindable -#endif -#endif { friend class HttpBrokerClient; friend class SessionButton; -#ifdef CFGPLUGIN - Q_PROPERTY ( QString x2goconfig READ x2goconfig WRITE setX2goconfig ) - Q_CLASSINFO ( "ClassID", "{5a20006d-118f-4185-9653-9f98958a0008}" ) - Q_CLASSINFO ( "InterfaceID", "{2df000ba-da4f-4fb7-8f35-b8dfbf80009a}" ) - Q_CLASSINFO ( "EventsID", "{44900013-f8bd-4d2e-a2cf-eab407c03005}" ) - Q_CLASSINFO ( "MIME", - "application/x2go:x2go:Configuration File " - "for X2Go Sessions" ) - Q_CLASSINFO ( "ToSuperClass", "ONMainWindow" ) - Q_CLASSINFO ( "DefaultProperty","x2goconfig" ) -#endif Q_OBJECT public: enum @@ -1228,50 +1195,6 @@ private: std::size_t default_size_for_key_type (key_types key_type); QString generateKey (key_types key_type, bool host_key = false); QString createKeyBundle (key_types key_type = RSA_KEY_TYPE); - -////////////////plugin stuff//////////////////// -#ifdef CFGPLUGIN -public slots: - void setX2goconfig ( const QString& text ); -public: - QString x2goconfig() const - { - return m_x2goconfig; - } - -#ifndef Q_OS_DARWIN -public: - void embedWindow ( long wndId ); - void detachClient(); -private: - long parentId; - long childId; - QSize oldParentSize; - -#ifdef Q_OS_LINUX - QX11EmbedContainer* embedContainer; -#endif -#ifdef Q_OS_WIN - QWidget* embedContainer; - QPoint oldParentPos; - QPoint oldChildPos; - QSize oldContainerSize; - QTimer *updateTimer; - int gcor; - long winFlags; -#endif -private: - QSize getWindowSize ( long winId ); - void doPluginInit(); - -#ifdef Q_OS_WIN -private slots: - void slotUpdateEmbedWindow(); -#endif - -#endif //(Q_OS_DARWIN) -#endif -////////////////end of plugin stuff//////////////////// }; #ifdef Q_OS_WIN diff --git a/src/onmainwindow_privat.h b/src/onmainwindow_privat.h index d272f71..0575c00 100644 --- a/src/onmainwindow_privat.h +++ b/src/onmainwindow_privat.h @@ -160,12 +160,5 @@ #include <X11/Xutil.h> #endif -#ifdef CFGPLUGIN -#ifdef Q_OS_LINUX -#include <dlfcn.h> -#include <QX11EmbedContainer> -#endif -#endif - #endif //ONMAINWINDOWPRIVAT_H -- Alioth's /home/x2go-admin/maintenancescripts/git/hooks/post-receive-email on /srv/git/code.x2go.org/x2goclient.git