office/texstudio: Upgraded to 2.6.4, added patch for Phonon

Signed-off-by: Robby Workman <rworkman@slackbuilds.org>
This commit is contained in:
larryhaja 2013-11-13 18:49:00 -08:00 committed by Robby Workman
parent 5073760b56
commit 8baf943fc2
3 changed files with 57 additions and 4 deletions

View file

@ -0,0 +1,51 @@
--- a/PDFDocument.cpp
+++ b/PDFDocument.cpp
@@ -781,19 +781,17 @@
event->accept();
}
-void PDFWidget::annotationClicked(Poppler::Annotation *annotation, const QPointF &scaledPos) {
+void PDFWidget::annotationClicked(Poppler::Annotation *annotation, int page) {
switch (annotation->subType()) {
case Poppler::Annotation::AMovie: {
#ifdef PHONON
- if (page > -1 && clickedAnnotation->boundary().contains(scaledPos) ) {
- if (movie) delete movie;
- movie = new PDFMovie(this, dynamic_cast<Poppler::MovieAnnotation*>(clickedAnnotation), page);
- movie->place();
- movie->show();
- movie->play();
- }
+ if (movie) delete movie;
+ movie = new PDFMovie(this, dynamic_cast<Poppler::MovieAnnotation*>(annotation), page);
+ movie->place();
+ movie->show();
+ movie->play();
#else
- Q_UNUSED(scaledPos)
+ Q_UNUSED(page)
txsWarning("You clicked on a video, but the video playing mode was disabled by you or the package creator.\nRecompile TeXstudio with the option PHONON=true");
#endif
break;
@@ -826,7 +824,9 @@
int page;
QPointF scaledPos;
mapToScaledPosition(event->pos(), page, scaledPos);
- annotationClicked(clickedAnnotation, scaledPos);
+ if (page > -1 && clickedAnnotation->boundary().contains(scaledPos)) {
+ annotationClicked(clickedAnnotation, page);
+ }
} else if (currentTool == kPresentation) {
if (event->button() == Qt::LeftButton) goNext();
else if (event->button() == Qt::RightButton) goPrev();
--- a/PDFDocument.h
+++ b/PDFDocument.h
@@ -237,7 +237,7 @@
void useMagnifier(const QMouseEvent *inEvent);
void goToDestination(const Poppler::LinkDestination& dest);
void doLink(const Poppler::Link *link);
- void annotationClicked(Poppler::Annotation *annotation, const QPointF &scaledPos);
+ void annotationClicked(Poppler::Annotation *annotation, int page);
void doZoom(const QPoint& clickPos, int dir, qreal newScaleFactor=1.0);
PDFScrollArea* getScrollArea();

View file

@ -23,7 +23,7 @@
# ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
PRGNAM=texstudio
VERSION=${VERSION:-2.6.2}
VERSION=${VERSION:-2.6.4}
BUILD=${BUILD:-1}
TAG=${TAG:-_SBo}
@ -71,6 +71,8 @@ find . \
# Fix .desktop item.
sed -i -e '/^Encoding/d' -e "/^Icon/s|=.*|=$PRGNAM|" utilities/texstudio.desktop
# Fix PHONON compile issue.
patch -p1 < $CWD/texstudio-2.6.4-phonon-build-fix.patch
qmake LIBS+="-L/usr/lib${LIBDIRSUFFIX}" QMAKE_CFLAGS+="$SLKCFLAGS" \
PHONON=true INCLUDEPATH+="/usr/include/KDE" QMAKE_CXXFLAGS+="$SLKCFLAGS"\

View file

@ -1,8 +1,8 @@
PRGNAM="texstudio"
VERSION="2.6.2"
VERSION="2.6.4"
HOMEPAGE="http://texstudio.sourceforge.net/"
DOWNLOAD="http://downloads.sourceforge.net/texstudio/texstudio-2.6.2.tar.gz"
MD5SUM="3a6f63c823d7c1a0417136e6e6b44265"
DOWNLOAD="http://downloads.sourceforge.net/texstudio/texstudio-2.6.4.tar.gz"
MD5SUM="216b30880b1a73bd98c2250cc6450f37"
DOWNLOAD_x86_64=""
MD5SUM_x86_64=""
REQUIRES=""