[prev in list] [next in list] [prev in thread] [next in thread]
List: kde-commits
Subject: KDE/kdegraphics/kviewshell/plugins/djvu
From: Stefan Kebekus <kebekus () kde ! org>
Date: 2006-05-20 11:03:42
Message-ID: 1148123022.621107.11041.nullmailer () svn ! kde ! org
[Download RAW message or body]
SVN commit 542791 by kebekus:
update page-deletion dialog; this now looks like in the working branch
M +4 -40 CMakeLists.txt
M +1 -1 djvumultipage.cpp
M +5 -4 pageRangeWidget.cpp
M +10 -11 pageRangeWidget.h
A pageRangeWidget.ui
D pageRangeWidget_base.ui
--- trunk/KDE/kdegraphics/kviewshell/plugins/djvu/CMakeLists.txt #542790:542791
@@ -16,8 +16,11 @@
kde4_automoc(${djvuviewpart_PART_SRCS})
-kde4_add_ui3_files(djvuviewpart_PART_SRCS \
kprintDialogPage_DJVUconversionoptions_basewidget.ui pageInsertionWidget_base.ui \
pageRangeWidget_base.ui ) +kde4_add_ui_files(djvuviewpart_PART_SRCS
+ pageRangeWidget.ui )
+kde4_add_ui3_files(djvuviewpart_PART_SRCS \
kprintDialogPage_DJVUconversionoptions_basewidget.ui pageInsertionWidget_base.ui ) +
kde4_add_kcfg_files(djvuviewpart_PART_SRCS prefs.kcfgc )
kde4_add_plugin(djvuviewpart ${djvuviewpart_PART_SRCS})
@@ -36,42 +39,3 @@
install_files( ${DATA_INSTALL_DIR}/kviewshell/plugins/djvu FILES )
install_files( ${SERVICES_INSTALL_DIR} FILES djvumultipage.desktop )
-
-
-
-#original Makefile.am contents follow:
-
-#INCLUDES = -I$(top_srcdir) $(all_includes) \
-# -I$(top_srcdir)/kviewshell/shell \
-# -I$(top_builddir)/kviewshell/shell \
-# -I$(kde_includes)/kviewshell/shell \
-# -I$(srcdir)/libdjvu
-#
-#SUBDIRS = libdjvu .
-#
-#KDE_CXXFLAGS = -Wno-deprecated
-#
-#METASOURCES = AUTO
-#
-## this is where the desktop file will go
-#kde_services_DATA = djvumultipage.desktop
-#
-## this is where the shell's XML-GUI resource file goes
-#shellrcdir = $(kde_datadir)/kviewshell/plugins/djvu
-#
-#kde_module_LTLIBRARIES = djvuviewpart.la
-#djvuviewpart_la_CXXFLAGS = -Wno-deprecated
-#djvuviewpart_la_LDFLAGS = $(all_libraries) $(KDE_PLUGIN) -module
-#djvuviewpart_la_LIBADD = -lkdeprint -lkparts \
$(top_builddir)/kviewshell/shell/libkmultipage.la libdjvu/libdjvu.la
-#djvuviewpart_la_SOURCES = djvumultipage.cpp djvurenderer.cpp \
kprintDialogPage_DJVUpageoptions.cpp \
-# kprintDialogPage_DJVUconversionoptions.cpp \
kprintDialogPage_DJVUconversionoptions_basewidget.ui \
-# pageInsertionWidget.cpp pageInsertionWidget_base.ui pageRangeWidget_base.ui \
pageRangeWidget.cpp \
-# prefs.kcfgc
-#
-#kde_kcfg_DATA = djvumultipage.kcfg
-#
-#pluginsdir = $(kde_datadir)
-#plugins_DATA = djvumultipage.rc
-#
-#messages: rc.cpp
-# $(XGETTEXT) *.cpp -o $(podir)/kdjview.pot
--- trunk/KDE/kdegraphics/kviewshell/plugins/djvu/djvumultipage.cpp #542790:542791
@@ -169,7 +169,7 @@
return;
KDialogBase dialog( parentWdg, "urldialog", true, i18n("Delete Pages"), \
KDialogBase::Ok|KDialogBase::Cancel, KDialogBase::Ok, true );
- PageRangeWidget range( 1, dataModel->numberOfPages(), \
dataModel->currentPageNumber(), &dialog, "range widget" ); + PageRangeWidget range( \
1, dataModel->numberOfPages(), dataModel->currentPageNumber(), &dialog); \
range.setToolTip( i18n( "Select the pages you wish to delete." ) ); \
dialog.setButtonOK(i18n("Delete Pages")); dialog.setMainWidget(&range);
--- trunk/KDE/kdegraphics/kviewshell/plugins/djvu/pageRangeWidget.cpp #542790:542791
@@ -1,5 +1,5 @@
/***************************************************************************
- * Copyright (C) 2005 by Stefan Kebekus *
+ * Copyright (C) 2005-2006 by Stefan Kebekus *
* kebekus@kde.org *
* *
* This program is free software; you can redistribute it and/or modify *
@@ -19,14 +19,13 @@
***************************************************************************/
#include "pageRangeWidget.h"
+
#include "kvs_debug.h"
-PageRangeWidget::PageRangeWidget( quint16 _from, quint16 _to, quint16 _current, \
QWidget *parent, const char *name) : PageRangeWidget_base(parent, name) \
+PageRangeWidget::PageRangeWidget( quint16 _from, quint16 _to, quint16 _current, \
QWidget *parent) : QWidget(parent) {
// Paranoid security checks
- if ((from == 0) || (to == 0))
- return;
if (_from > _to) {
kError(kvs::djvu) << "PageRangeWidget::PageRangeWidget(..): from > to" << endl;
_to = _from;
@@ -40,6 +39,8 @@
_current = _to;
}
+ setupUi( this );
+
connect(from, SIGNAL(valueChanged(int)), this, SLOT(fromValueChanged(int)));
connect(to, SIGNAL(valueChanged(int)), this, SLOT(toValueChanged(int)));
--- trunk/KDE/kdegraphics/kviewshell/plugins/djvu/pageRangeWidget.h #542790:542791
@@ -1,5 +1,5 @@
/***************************************************************************
- * Copyright (C) 2005 by Stefan Kebekus *
+ * Copyright (C) 2005-2006 by Stefan Kebekus *
* kebekus@kde.org *
* *
* This program is free software; you can redistribute it and/or modify *
@@ -15,27 +15,26 @@
* You should have received a copy of the GNU General Public License *
* along with this program; if not, write to the *
* Free Software Foundation, Inc., *
- * 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. *
+ * 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. *
***************************************************************************/
#ifndef PAGERANGEWIDGET_H
#define PAGERANGEWIDGET_H
-#include <knuminput.h>
+#include <QWidget>
+#include "ui_pageRangeWidget.h"
-#include "pageRangeWidget_base.h"
-
-class PageRangeWidget : public PageRangeWidget_base
+class PageRangeWidget : public QWidget, private Ui_PageRangeWidget
{
Q_OBJECT
public:
- PageRangeWidget( quint16 _from, quint16 _to, quint16 _current, QWidget *parent = \
0, const char *name = 0 );
-
- quint16 getFrom() const {return (from == 0) ? 0 : from->value(); }
- quint16 getTo() const {return (to == 0) ? 0 : to->value(); }
-
+ PageRangeWidget( quint16 _from, quint16 _to, quint16 _current, QWidget *parent = \
0); +
+ quint16 getFrom() const { return from->value(); }
+ quint16 getTo() const { return to->value(); }
+
private slots:
void toValueChanged(int val);
void fromValueChanged(int val);
[prev in list] [next in list] [prev in thread] [next in thread]
Configure |
About |
News |
Add a list |
Sponsored by KoreLogic