From: Mateusz Półrola Date: Tue, 5 Oct 2010 13:13:43 +0000 (+0200) Subject: Fixed bug in star dict reader X-Git-Url: https://vcs.maemo.org/git/?a=commitdiff_plain;h=7d0de32eebb30f6aeaa02f722cbc2c722e140b0d;p=mdictionary Fixed bug in star dict reader --- diff --git a/src/plugins/stardict/StarDialog.h b/src/plugins/stardict/StarDialog.h index 85a08cc..5348b17 100644 --- a/src/plugins/stardict/StarDialog.h +++ b/src/plugins/stardict/StarDialog.h @@ -33,7 +33,7 @@ #include "StarDictPlugin.h" -//! Implementation of xdxf plugin's dialogs. +//! Implementation of stardict plugin's dialogs. /*! This class can create dialogs for adding a new dictionary or changing settings of an existing one, based on dialog type passed to contructor. diff --git a/src/plugins/stardict/StarDictReaderFactory.cpp b/src/plugins/stardict/StarDictReaderFactory.cpp index 757517f..498bdfc 100644 --- a/src/plugins/stardict/StarDictReaderFactory.cpp +++ b/src/plugins/stardict/StarDictReaderFactory.cpp @@ -27,16 +27,12 @@ StarDictReader* StarDictReaderFactory::createReader(QString filename) { - StarDictReader* reader; if(filename.endsWith(".gz", Qt::CaseInsensitive) || filename.endsWith(".dz", Qt::CaseInsensitive)) { - reader = new CompressedReader(); + return new CompressedReader(filename); } else { - reader = new UncompressedReader(); + return new UncompressedReader(filename); } - - reader->open(filename); - return reader; }