mirror of
https://invent.kde.org/graphics/okular
synced 2024-11-05 18:34:53 +00:00
chm generator no longer needs qt3support
svn path=/trunk/playground/graphics/okular/; revision=588870
This commit is contained in:
parent
42310e184c
commit
f67a7f00a6
6 changed files with 30 additions and 12 deletions
|
@ -1,7 +1,5 @@
|
|||
add_subdirectory( kio-msits )
|
||||
|
||||
add_definitions (-DQT3_SUPPORT -DQT3_SUPPORT_WARNINGS)
|
||||
|
||||
include_directories(
|
||||
${CMAKE_SOURCE_DIR}/okular
|
||||
${CMAKE_BINARY_DIR}/okular
|
||||
|
|
|
@ -154,7 +154,12 @@ bool CHMGenerator::canGeneratePixmap ( bool /*async*/ )
|
|||
kDebug() << "async is locked " << asyncLock.locked() << endl;
|
||||
return !asyncLock.locked();
|
||||
}*/
|
||||
return !syncLock.locked();
|
||||
bool isLocked = true;
|
||||
if (syncLock.tryLock()) {
|
||||
syncLock.unlock();
|
||||
isLocked = false;
|
||||
}
|
||||
return !isLocked;
|
||||
}
|
||||
|
||||
void CHMGenerator::generatePixmap( Okular::PixmapRequest * request )
|
||||
|
|
|
@ -1,4 +1,6 @@
|
|||
|
||||
#if 0
|
||||
|
||||
/***************************************************************************
|
||||
* Copyright (C) 2005 by Georgy Yunaev *
|
||||
* tim@krasnogorsk.ru *
|
||||
|
@ -136,3 +138,6 @@ int KCHMMainTreeViewItem::width( const QFontMetrics & fm, const Q3ListView * lv,
|
|||
(QFontMetrics (myFont), lv, c));
|
||||
}
|
||||
*/
|
||||
|
||||
#endif
|
||||
|
||||
|
|
|
@ -1,3 +1,5 @@
|
|||
|
||||
|
||||
/***************************************************************************
|
||||
* Copyright (C) 2005 by Georgy Yunaev *
|
||||
* tim@krasnogorsk.ru *
|
||||
|
@ -20,8 +22,6 @@
|
|||
#ifndef CTREEVIEWITEM_H
|
||||
#define CTREEVIEWITEM_H
|
||||
|
||||
#include <k3listview.h>
|
||||
|
||||
namespace KCHMImageType
|
||||
{
|
||||
const int IMAGE_NONE = -1;
|
||||
|
@ -29,6 +29,10 @@ namespace KCHMImageType
|
|||
const int IMAGE_INDEX = -3;
|
||||
};
|
||||
|
||||
#if 0
|
||||
|
||||
#include <k3listview.h>
|
||||
|
||||
/**
|
||||
@author Georgy Yunaev
|
||||
*/
|
||||
|
@ -52,3 +56,5 @@ private:
|
|||
};
|
||||
|
||||
#endif
|
||||
|
||||
#endif
|
||||
|
|
|
@ -29,7 +29,7 @@
|
|||
#include <qeventloop.h>
|
||||
#include <qdom.h>
|
||||
#include <qfile.h>
|
||||
#include <k3listview.h>
|
||||
// #include <k3listview.h>
|
||||
|
||||
#include "xchmfile.h"
|
||||
#include "iconstorage.h"
|
||||
|
@ -530,6 +530,7 @@ bool CHMFile::ParseHhcAndFillTree (const QString& file, QDomDocument *tree, bool
|
|||
return true;
|
||||
}
|
||||
|
||||
#if 0
|
||||
bool CHMFile::ParseHhcAndFillTree (const QString& file, K3ListView *tree, bool asIndex)
|
||||
{
|
||||
chmUnitInfo ui;
|
||||
|
@ -705,18 +706,22 @@ bool CHMFile::ParseHhcAndFillTree (const QString& file, K3ListView *tree, bool a
|
|||
|
||||
return true;
|
||||
}
|
||||
|
||||
#endif
|
||||
|
||||
bool CHMFile::ParseAndFillTopicsTree(QDomDocument *tree)
|
||||
{
|
||||
return ParseHhcAndFillTree (m_topicsFile, tree, false);
|
||||
}
|
||||
|
||||
#if 0
|
||||
|
||||
bool CHMFile::ParseAndFillIndex(K3ListView *indexlist)
|
||||
{
|
||||
return ParseHhcAndFillTree (m_indexFile, indexlist, true);
|
||||
}
|
||||
|
||||
#endif
|
||||
|
||||
bool CHMFile::SearchWord (const QString& text, bool wholeWords, bool titlesOnly, KCHMSearchProgressResults_t& results, bool phrase_search)
|
||||
{
|
||||
bool partial = false;
|
||||
|
|
|
@ -37,10 +37,9 @@
|
|||
#include "kchmtextencoding.h"
|
||||
|
||||
#include "chm_lib.h"
|
||||
// #include
|
||||
|
||||
class CHMGenerator;
|
||||
class K3ListView;
|
||||
|
||||
class KCHMSearchResult
|
||||
{
|
||||
public:
|
||||
|
@ -178,7 +177,7 @@ public:
|
|||
to this function.
|
||||
\return true if it's possible to build the tree, false otherwise.
|
||||
*/
|
||||
bool ParseAndFillTopicsTree(QDomDocument*toBuild);
|
||||
bool ParseAndFillTopicsTree(QDomDocument*toBuild);
|
||||
|
||||
/*!
|
||||
\brief Attempts to fill a QListView by parsing the index file.
|
||||
|
@ -188,7 +187,7 @@ public:
|
|||
to this function.
|
||||
\return true if it's possible to build the tree, false otherwise.
|
||||
*/
|
||||
bool ParseAndFillIndex (K3ListView *indexlist);
|
||||
// bool ParseAndFillIndex (K3ListView *indexlist);
|
||||
|
||||
/*!
|
||||
\brief Fast search using the $FIftiMain file in the .chm.
|
||||
|
@ -277,7 +276,7 @@ public:
|
|||
private:
|
||||
//! Parse the HHC or HHS file, and fill the context (asIndex is false) or index (asIndex is true) tree.
|
||||
bool ParseHhcAndFillTree (const QString& file, QDomDocument *tree, bool asIndex);
|
||||
bool ParseHhcAndFillTree (const QString& file, K3ListView *tree, bool asIndex);
|
||||
// bool ParseHhcAndFillTree (const QString& file, K3ListView *tree, bool asIndex);
|
||||
//! Parse the HHC or HHS file, and fill the data.
|
||||
bool ParseChmIndexFile ( const QString& file, bool asIndex, KCHMParsedIndexEntry_t & cont );
|
||||
|
||||
|
|
Loading…
Reference in a new issue