From owner-svn-ports-head@freebsd.org Wed Sep 4 02:08:28 2019 Return-Path: Delivered-To: svn-ports-head@mailman.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mailman.nyi.freebsd.org (Postfix) with ESMTP id 4F90DE10E4; Wed, 4 Sep 2019 02:08:28 +0000 (UTC) (envelope-from fox@FreeBSD.org) Received: from mxrelay.nyi.freebsd.org (mxrelay.nyi.freebsd.org [IPv6:2610:1c1:1:606c::19:3]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) server-signature RSA-PSS (4096 bits) client-signature RSA-PSS (4096 bits) client-digest SHA256) (Client CN "mxrelay.nyi.freebsd.org", Issuer "Let's Encrypt Authority X3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 46NS0X1SPfz4fhb; Wed, 4 Sep 2019 02:08:28 +0000 (UTC) (envelope-from fox@FreeBSD.org) Received: from repo.freebsd.org (repo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:0]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mxrelay.nyi.freebsd.org (Postfix) with ESMTPS id 1196AC6E4; Wed, 4 Sep 2019 02:08:28 +0000 (UTC) (envelope-from fox@FreeBSD.org) Received: from repo.freebsd.org ([127.0.1.37]) by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id x8428Rbc097374; Wed, 4 Sep 2019 02:08:27 GMT (envelope-from fox@FreeBSD.org) Received: (from fox@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id x8428R1N097372; Wed, 4 Sep 2019 02:08:27 GMT (envelope-from fox@FreeBSD.org) Message-Id: <201909040208.x8428R1N097372@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: fox set sender to fox@FreeBSD.org using -f From: Santhosh Raju Date: Wed, 4 Sep 2019 02:08:27 +0000 (UTC) To: ports-committers@freebsd.org, svn-ports-all@freebsd.org, svn-ports-head@freebsd.org Subject: svn commit: r511054 - in head/graphics/dspdfviewer: . files X-SVN-Group: ports-head X-SVN-Commit-Author: fox X-SVN-Commit-Paths: in head/graphics/dspdfviewer: . files X-SVN-Commit-Revision: 511054 X-SVN-Commit-Repository: ports MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-ports-head@freebsd.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: SVN commit messages for the ports tree for head List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 04 Sep 2019 02:08:28 -0000 Author: fox Date: Wed Sep 4 02:08:27 2019 New Revision: 511054 URL: https://svnweb.freebsd.org/changeset/ports/511054 Log: graphics/dspdfviewer: Fixes build with Qt 5.13 Submitted by: adridg Approved by: philip (mentor) Added: head/graphics/dspdfviewer/files/patch-pdfviewerwindow.cpp (contents, props changed) Modified: head/graphics/dspdfviewer/Makefile Modified: head/graphics/dspdfviewer/Makefile ============================================================================== --- head/graphics/dspdfviewer/Makefile Wed Sep 4 01:22:51 2019 (r511053) +++ head/graphics/dspdfviewer/Makefile Wed Sep 4 02:08:27 2019 (r511054) @@ -3,7 +3,7 @@ PORTNAME= dspdfviewer PORTVERSION= 1.15.1 DISTVERSIONPREFIX= v -PORTREVISION= 19 +PORTREVISION= 20 CATEGORIES= graphics MAINTAINER= fox@FreeBSD.org Added: head/graphics/dspdfviewer/files/patch-pdfviewerwindow.cpp ============================================================================== --- /dev/null 00:00:00 1970 (empty, because file is newly added) +++ head/graphics/dspdfviewer/files/patch-pdfviewerwindow.cpp Wed Sep 4 02:08:27 2019 (r511054) @@ -0,0 +1,42 @@ + Fix graphics/dspdfviewer build w/ Qt 5.13 + + - adjust to deprecated methods + - QApplication::flush() hasn't really been a thing since Qt4, + just comment it out. + +The application looks abandoned upstream. + +Patched by adridg@freebsd.org +--- pdfviewerwindow.cpp.orig 2016-09-13 13:18:47 UTC ++++ pdfviewerwindow.cpp +@@ -24,6 +24,7 @@ + #include + #include + #include ++#include + #if defined(POPPLER_QT5) && defined(_WIN32) + #include + #endif +@@ -116,7 +117,12 @@ void PDFViewerWindow::reposition() + this->windowHandle()->setScreen(0); + this->showFullScreen(); + #else +- QRect rect = QApplication::desktop()->screenGeometry( numeric_cast(getMonitor()) ); ++ auto screens = QGuiApplication::screens(); ++ int screen_number = numeric_cast(getMonitor()); ++ if ((screen_number < 0) || (screen_number >= screens.length())) { ++ screen_number = 0; ++ } ++ QRect rect = screens.at(screen_number)->geometry(); + move(rect.topLeft()); + resize( rect.size() ); + this->showFullScreen(); +@@ -381,7 +387,7 @@ void PDFViewerWindow::resizeEvent(QResizeEvent* resize + ! i3shellcode_executed + // Make sure to do this only once + ) { +- QApplication::flush(); // Make sure the window has been painted ++ // QApplication::flush(); // Make sure the window has been painted + // This is the second screen. It has now been created. + // so we should call the i3 shellcode now + const std::string shellcode = runtimeConfiguration.i3workaround_shellcode();