removing warning act 2

preferencesAboutTextFull
Claudio Valerio 13 years ago
parent c8a88bbb58
commit cf91bdd07f
  1. 1
      src/customWidgets/UBActionableWidget.cpp
  2. 2
      src/customWidgets/UBDraggableMedia.cpp
  3. 1
      src/gui/UBTBPageEditWidget.cpp
  4. 13
      src/pdf-merger/ASCII85Decode.cpp
  5. 4
      src/pdf-merger/ASCII85Decode.h
  6. 13
      src/pdf-merger/ASCIIHexDecode.cpp
  7. 4
      src/pdf-merger/ASCIIHexDecode.h
  8. 36
      src/pdf-merger/CCITTFaxDecode.cpp
  9. 8
      src/pdf-merger/CCITTFaxDecode.h
  10. 1
      src/pdf-merger/ContentHandler.cpp
  11. 36
      src/pdf-merger/DCTDecode.cpp
  12. 8
      src/pdf-merger/DCTDecode.h
  13. 3
      src/pdf-merger/Document.cpp
  14. 7
      src/pdf-merger/FilterPredictor.cpp
  15. 2
      src/pdf-merger/FilterPredictor.h
  16. 36
      src/pdf-merger/JBIG2Decode.cpp
  17. 7
      src/pdf-merger/JBIG2Decode.h
  18. 5
      src/pdf-merger/LZWDecode.cpp
  19. 2
      src/pdf-merger/LZWDecode.h
  20. 8
      src/pdf-merger/PageElementHandler.cpp
  21. 4
      src/pdf-merger/PageElementHandler.h
  22. 14
      src/pdf-merger/RunLengthDecode.cpp
  23. 4
      src/pdf-merger/RunLengthDecode.h
  24. 8
      src/pdf-merger/pdfMerger.pri

@ -57,6 +57,7 @@ bool UBActionableWidget::shouldClose(QPoint p)
void UBActionableWidget::paintEvent(QPaintEvent* ev) void UBActionableWidget::paintEvent(QPaintEvent* ev)
{ {
Q_UNUSED(ev);
if(mShowActions){ if(mShowActions){
QPainter p(this); QPainter p(this);
if(mActions.contains(eAction_Close)){ if(mActions.contains(eAction_Close)){

@ -38,5 +38,5 @@ void UBDraggableMedia::mouseMoveEvent(QMouseEvent* ev)
drag->setMimeData(mimeData); drag->setMimeData(mimeData);
Qt::DropAction dropAction = drag->exec(Qt::CopyAction | Qt::MoveAction); drag->exec(Qt::CopyAction | Qt::MoveAction);
} }

@ -578,5 +578,6 @@ UBPictureWidget::~UBPictureWidget()
void UBPictureWidget::resizeEvent(QResizeEvent *ev) void UBPictureWidget::resizeEvent(QResizeEvent *ev)
{ {
Q_UNUSED(ev);
mpLabel->setGeometry( 10, 10, width()-2*10, height()); mpLabel->setGeometry( 10, 10, width()-2*10, height());
} }

@ -13,7 +13,7 @@
* along with this program. If not, see <http://www.gnu.org/licenses/>. * along with this program. If not, see <http://www.gnu.org/licenses/>.
*/ */
#include <iostream> #include <iostream>
#include <QtGlobal>
#include "ASCII85Decode.h" #include "ASCII85Decode.h"
#include "core/memcheck.h" #include "core/memcheck.h"
@ -51,6 +51,12 @@ void ASCII85Decode::_wput(std::string &cur,unsigned long tuple, int len)
} }
} }
bool ASCII85Decode::encode(std::string & decoded)
{
Q_UNUSED(decoded);
return false;
}
bool ASCII85Decode::decode(std::string &encoded) bool ASCII85Decode::decode(std::string &encoded)
{ {
unsigned long tuple = 0; unsigned long tuple = 0;
@ -58,7 +64,6 @@ bool ASCII85Decode::decode(std::string &encoded)
int count = 0; int count = 0;
int size = encoded.size(); int size = encoded.size();
int i = 0; int i = 0;
bool found = false;
for(;size;) for(;size;)
{ {
char ch = encoded[i++]; char ch = encoded[i++];
@ -121,3 +126,7 @@ bool ASCII85Decode::decode(std::string &encoded)
} }
return true; return true;
} }
void ASCII85Decode::initialize(Object * objectWithStram)
{
Q_UNUSED(objectWithStram);
};

@ -26,9 +26,9 @@ namespace merge_lib
public: public:
ASCII85Decode(){}; ASCII85Decode(){};
virtual ~ASCII85Decode(){}; virtual ~ASCII85Decode(){};
bool encode(std::string & decoded) {return false;} bool encode(std::string & decoded);
bool decode(std::string & encoded); bool decode(std::string & encoded);
void initialize(Object * objectWithStram){}; void initialize(Object * objectWithStram);
private: private:
void _wput(std::string &cur,unsigned long tuple, int len); void _wput(std::string &cur,unsigned long tuple, int len);

@ -13,7 +13,7 @@
* along with this program. If not, see <http://www.gnu.org/licenses/>. * along with this program. If not, see <http://www.gnu.org/licenses/>.
*/ */
#include "ASCIIHexDecode.h" #include "ASCIIHexDecode.h"
#include <QtGlobal>
#include <string> #include <string>
#include "Utils.h" #include "Utils.h"
@ -42,6 +42,12 @@ static unsigned int convertHexVal(unsigned char c)
return 0; return 0;
} }
bool ASCIIHexDecode::encode(std::string & decoded)
{
Q_UNUSED(decoded);
return false;
}
bool ASCIIHexDecode::decode(std::string & encoded) bool ASCIIHexDecode::decode(std::string & encoded)
{ {
bool isLow = true; bool isLow = true;
@ -75,3 +81,8 @@ bool ASCIIHexDecode::decode(std::string & encoded)
encoded = decoded; encoded = decoded;
return true; return true;
} }
void ASCIIHexDecode::initialize(Object * objectWithStram)
{
Q_UNUSED(objectWithStram);
}

@ -26,9 +26,9 @@ namespace merge_lib
public: public:
ASCIIHexDecode(){}; ASCIIHexDecode(){};
virtual ~ASCIIHexDecode(){}; virtual ~ASCIIHexDecode(){};
bool encode(std::string & decoded){return false;} bool encode(std::string & decoded);
bool decode(std::string & encoded); bool decode(std::string & encoded);
void initialize(Object * objectWithStram){}; void initialize(Object * objectWithStram);
}; };
} }

@ -0,0 +1,36 @@
/*
* 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
* the Free Software Foundation, either version 3 of the License, or
* (at your option) any later version.
*
* This program is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* 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/>.
*/
#include <QtGlobal>
#include "CCITTFaxDecode.h"
using namespace merge_lib;
bool CCITTFaxDecode::encode(std::string & decoded)
{
Q_UNUSED(decoded);
return true;
}
bool CCITTFaxDecode::decode(std::string & encoded)
{
Q_UNUSED(encoded);
return true;
}
void CCITTFaxDecode::initialize(Object * objectWithStram)
{
Q_UNUSED(objectWithStram);
}

@ -16,6 +16,8 @@
#define CCITTFaxDecode_H #define CCITTFaxDecode_H
#include <string> #include <string>
#include "Decoder.h"
namespace merge_lib namespace merge_lib
{ {
// this class provides method for FlateDecode encoding and decoding // this class provides method for FlateDecode encoding and decoding
@ -24,9 +26,9 @@ namespace merge_lib
public: public:
CCITTFaxDecode(){}; CCITTFaxDecode(){};
virtual ~CCITTFaxDecode(){}; virtual ~CCITTFaxDecode(){};
bool encode(std::string & decoded) {return true;}; bool encode(std::string & decoded);
bool decode(std::string & encoded) {return true;}; bool decode(std::string & encoded);
void initialize(Object * objectWithStram){}; void initialize(Object * objectWithStram);
}; };
} }

@ -12,6 +12,7 @@
* You should have received a copy of the GNU General Public License * 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 <http://www.gnu.org/licenses/>.
*/ */
#include "ContentHandler.h" #include "ContentHandler.h"
#include "Filter.h" #include "Filter.h"
#include "FlateDecode.h" #include "FlateDecode.h"

@ -0,0 +1,36 @@
/*
* 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
* the Free Software Foundation, either version 3 of the License, or
* (at your option) any later version.
*
* This program is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* 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/>.
*/
#include <QtGlobal>
#include "DCTDecode.h"
using namespace merge_lib;
bool DCTDecode::encode(std::string & decoded)
{
Q_UNUSED(decoded);
return true;
}
bool DCTDecode::decode(std::string & encoded)
{
Q_UNUSED(encoded);
return true;
}
void DCTDecode::initialize(Object * objectWithStram)
{
Q_UNUSED(objectWithStram);
}

@ -16,7 +16,7 @@
#define DCTDecode_H #define DCTDecode_H
#include <string> #include <string>
#include "Decoder.h"
namespace merge_lib namespace merge_lib
{ {
// this class provides method for FlateDecode encoding and decoding // this class provides method for FlateDecode encoding and decoding
@ -25,9 +25,9 @@ namespace merge_lib
public: public:
DCTDecode(){}; DCTDecode(){};
virtual ~DCTDecode(){}; virtual ~DCTDecode(){};
bool encode(std::string & decoded) {return true;}; bool encode(std::string & decoded);
bool decode(std::string & encoded) {return true;}; bool decode(std::string & encoded);
void initialize(Object * objectWithStram){}; void initialize(Object * objectWithStram);
}; };
} }

@ -28,7 +28,8 @@
using namespace merge_lib; using namespace merge_lib;
const std::string firstObj("%PDF-1.4\n1 0 obj\n<<\n/Title ()/Creator ()/Producer (Qt 4.5.0 (C) 1992-2009 Nokia Corporation and/or its subsidiary(-ies))/CreationDate (D:20090424120829)\n>>\nendobj\n"); const std::string firstObj("%PDF-1.4\n1 0 obj\n<<\n/Title ()/Creator ()/Producer (Qt 4.5.0 (C) 1992-2009 Nokia Corporation and/or its subsidiary(-ies))/CreationDate (D:20090424120829)\n>>\nendobj\n");
const std::string zeroStr("0000000000"); const std::string zeroStr("0000000000");
Document::Document(const char * fileName): _pages(), _maxObjectNumber(0),_root(0),_documentName(fileName) Document::Document(const char * fileName):
_root(0), _pages(), _documentName(fileName), _maxObjectNumber(0)
{ {
} }

@ -15,6 +15,7 @@
#include "Config.h" #include "Config.h"
#include <iostream> #include <iostream>
#include <map> #include <map>
#include <QtGlobal>
#include "FilterPredictor.h" #include "FilterPredictor.h"
#include "Utils.h" #include "Utils.h"
@ -49,6 +50,12 @@ FilterPredictor::~FilterPredictor()
{ {
} }
bool FilterPredictor::encode(std::string & decoded)
{
Q_UNUSED(decoded);
return false;
}
std::string FilterPredictor::getDictionaryContentStr(std::string & in, size_t &pos ) std::string FilterPredictor::getDictionaryContentStr(std::string & in, size_t &pos )
{ {
size_t beg = in.find(DICT_START_TOKEN,pos); size_t beg = in.find(DICT_START_TOKEN,pos);

@ -27,7 +27,7 @@ namespace merge_lib
public: public:
FilterPredictor(); FilterPredictor();
virtual ~FilterPredictor(); virtual ~FilterPredictor();
bool encode(std::string & decoded){return false;} bool encode(std::string & decoded);
bool decode(std::string & encoded); bool decode(std::string & encoded);
void initialize(Object * objectWithStream); void initialize(Object * objectWithStream);

@ -0,0 +1,36 @@
/*
* 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
* the Free Software Foundation, either version 3 of the License, or
* (at your option) any later version.
*
* This program is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* 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/>.
*/
#include <QtGlobal>
#include "JBIG2Decode.h"
using namespace merge_lib;
bool JBIG2Decode::encode(std::string & decoded)
{
Q_UNUSED(decoded);
return true;
}
bool JBIG2Decode::decode(std::string & encoded)
{
Q_UNUSED(encoded);
return true;
}
void JBIG2Decode::initialize(Object * objectWithStram)
{
Q_UNUSED(objectWithStram);
}

@ -16,6 +16,7 @@
#define JBIG2Decode_H #define JBIG2Decode_H
#include <string> #include <string>
#include "Decoder.h"
namespace merge_lib namespace merge_lib
{ {
@ -25,9 +26,9 @@ namespace merge_lib
public: public:
JBIG2Decode(){}; JBIG2Decode(){};
virtual ~JBIG2Decode(){}; virtual ~JBIG2Decode(){};
bool encode(std::string & decoded) {return true;}; bool encode(std::string & decoded);
bool decode(std::string & encoded) {return true;}; bool decode(std::string & encoded);
void initialize(Object * objectWithStram){}; void initialize(Object * objectWithStram);
}; };
} }

@ -44,6 +44,11 @@ LZWDecode::~LZWDecode()
} }
} }
bool LZWDecode::encode(std::string & decoded)
{
return true;
}
void LZWDecode::initialize(Object * objectWithStream) void LZWDecode::initialize(Object * objectWithStream)
{ {
if( objectWithStream ) if( objectWithStream )

@ -27,7 +27,7 @@ namespace merge_lib
public: public:
LZWDecode(); LZWDecode();
virtual ~LZWDecode(); virtual ~LZWDecode();
bool encode(std::string & decoded) {return true;}; bool encode(std::string & decoded);
bool decode(std::string & encoded); bool decode(std::string & encoded);
void initialize(Object * objectWithStram); void initialize(Object * objectWithStram);
private: private:

@ -12,8 +12,9 @@
* You should have received a copy of the GNU General Public License * 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 <http://www.gnu.org/licenses/>.
*/ */
#include "PageElementHandler.h"
#include "PageElementHandler.h"
#include <QtGlobal>
#include "core/memcheck.h" #include "core/memcheck.h"
using namespace merge_lib; using namespace merge_lib;
@ -88,3 +89,8 @@ unsigned int PageElementHandler::_findEndOfElementContent(unsigned int startOfPa
} }
return _pageContent.rfind(">>"); return _pageContent.rfind(">>");
} }
void PageElementHandler::_processObjectContent(unsigned int startOfPageElement)
{
Q_UNUSED(startOfPageElement);
}

@ -73,14 +73,14 @@ namespace merge_lib
void _createAllPageFieldsSet(); void _createAllPageFieldsSet();
//members //members
std::string & _pageContent;
Object * _page; Object * _page;
std::string & _pageContent;
std::string _handlerName; std::string _handlerName;
PageElementHandler * _nextHandler; PageElementHandler * _nextHandler;
private: private:
//methods //methods
virtual void _processObjectContent(unsigned int startOfPageElement){}; virtual void _processObjectContent(unsigned int startOfPageElement);
virtual void _changeObjectContent(unsigned int startOfPageElement) = 0; virtual void _changeObjectContent(unsigned int startOfPageElement) = 0;
virtual void _pageElementNotFound() {}; virtual void _pageElementNotFound() {};
unsigned int _findStartOfPageElement() unsigned int _findStartOfPageElement()

@ -12,12 +12,19 @@
* You should have received a copy of the GNU General Public License * 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 <http://www.gnu.org/licenses/>.
*/ */
#include "RunLengthDecode.h"
#include "RunLengthDecode.h"
#include <QtGlobal>
#include "core/memcheck.h" #include "core/memcheck.h"
using namespace merge_lib; using namespace merge_lib;
bool RunLengthDecode::encode(std::string & decoded)
{
Q_UNUSED(decoded);
return false;
}
/* The encoded data is a sequence of /* The encoded data is a sequence of
runs, where each run consists of a length byte followed by 1 to 128 bytes of data. If runs, where each run consists of a length byte followed by 1 to 128 bytes of data. If
the length byte is in the range 0 to 127, the following length + 1 (1 to 128) bytes the length byte is in the range 0 to 127, the following length + 1 (1 to 128) bytes
@ -57,3 +64,8 @@ bool RunLengthDecode::decode(std::string & encoded)
} }
return true; return true;
} }
void RunLengthDecode::initialize(Object * objectWithStream)
{
Q_UNUSED(objectWithStream);
};

@ -26,9 +26,9 @@ namespace merge_lib
public: public:
RunLengthDecode(){}; RunLengthDecode(){};
virtual ~RunLengthDecode(){}; virtual ~RunLengthDecode(){};
bool encode(std::string & decoded){return false;} bool encode(std::string & decoded);
bool decode(std::string & encoded); bool decode(std::string & encoded);
void initialize(Object * objectWithStream){}; void initialize(Object * objectWithStream);
}; };
} }

@ -54,7 +54,10 @@ SOURCES += \
RemoveHimselfHandler.cpp \ RemoveHimselfHandler.cpp \
RunLengthDecode.cpp \ RunLengthDecode.cpp \
Utils.cpp \ Utils.cpp \
OverlayDocumentParser.cpp OverlayDocumentParser.cpp \
src/pdf-merger/CCITTFaxDecode.cpp \
src/pdf-merger/JBIG2Decode.cpp \
src/pdf-merger/DCTDecode.cpp
macx { macx {
@ -83,3 +86,6 @@ linux-g++-64 {
LIBS += -lz LIBS += -lz
} }

Loading…
Cancel
Save