[SCM] 2D CAD system branch, master, updated. debian/1.0.0_beta5-1-8-g0826131

Scott Howard showard314 at gmail.com
Thu Feb 3 02:22:48 UTC 2011


The following commit has been merged in the master branch:
commit 082613182a29d77a195b316ce96814e2efec994a
Author: Scott Howard <showard314 at gmail.com>
Date:   Wed Feb 2 21:22:09 2011 -0500

    minor fixes before uploading for ubuntu

diff --git a/debian/changelog b/debian/changelog
index e7fac2c..c1a43d0 100644
--- a/debian/changelog
+++ b/debian/changelog
@@ -2,4 +2,4 @@ librecad (1.0.0~beta5-1) UNRELEASED; urgency=low
 
   * Initial release (Closes: #605914)
 
- -- Scott Howard <showard314 at gmail.com>  Sun, 05 Dec 2010 18:24:07 -0500
+ -- Scott Howard <showard at debian.org>  Wed, 02 Feb 2011 21:13:56 -0500
diff --git a/debian/control b/debian/control
index 55b845d..8b622f9 100644
--- a/debian/control
+++ b/debian/control
@@ -2,7 +2,7 @@ Source: librecad
 Section: graphics
 Priority: optional
 Maintainer: Debian Science Maintainers <debian-science-maintainers at lists.alioth.debian.org>
-Uploaders: Scott Howard <showard314 at gmail.com>, Ruben Molina <rmolina at udea.edu.co>
+Uploaders: Scott Howard <showard at debian.org>, Ruben Molina <rmolina at udea.edu.co>
 Build-Depends: debhelper (>= 8), libqt4-dev
 Standards-Version: 3.9.1
 Homepage: http://www.librecad.org/
@@ -13,7 +13,7 @@ Vcs-Browser: http://git.debian.org/?p=debian-science/packages/librecad.git
 
 Package: librecad
 Architecture: any
-Depends: ${shlibs:Depends}, ${misc:Depends}, librecad-data (>= ${source:Version})
+Depends: ${shlibs:Depends}, ${misc:Depends}, librecad-data (= ${source:Version})
 Recommends: librecad-doc (= ${source:Version})
 Description: Computer-aided design (CAD) system
  LibreCAD is an application for computer aided design (CAD) in two
diff --git a/debian/copyright b/debian/copyright
index 7cd6945..ed6c4b4 100644
--- a/debian/copyright
+++ b/debian/copyright
@@ -3,10 +3,7 @@ Upstream-Name: LibreCAD
 Upstream-Contact: Ries van Twisk <ries at vantwisk.nl>
 Source: http://www.librecad.org/
 
-Name: libreCAD
-Maintainer: Ries van Twisk <ries at vantwisk.nl>
-Source: http://www.librecad.org/
-
+Files: *
 Copyright: 2001-2003, RibbonSoft GmbH <www.qcad.com>
            2010, Ries van Twisk <ries at vantwisk.nl>
 License: GPL-2+
@@ -29,9 +26,9 @@ License: GPL-2+
     On Debian systems, the complete text of the GNU General Public License 
     version 2 can be found in `/usr/share/common-licenses/GPL-2'.
 
-Files: ./dxflib/test/test_creationclass.h, ./dxflib/test/main.cpp, ./dxflib/test/test_creationclass.cpp
+Files: dxflib/test/test_creationclass.h dxflib/test/main.cpp dxflib/test/test_creationclass.cpp
 Copyright: 2001, Andrew Mustun <andrew at ribbonsoft.com>
-License: LGPL
+License: LGPL-2
     This program is free software; you can redistribute it and/or modify
     it under the terms of the GNU Library General Public License as
     published by the Free Software Foundation.
@@ -51,51 +48,119 @@ License: LGPL
 Files: fparser/*
 Copyright: 2003, Juha Nieminen
            2003, Joel Yliluoma <warp at iki.fi>
-License: other
-  1. This library is free for non-commercial usage. You can do whatever you
-     like with it as long as you don't claim you made it yourself.
-    .
-  2. It is possible to use this library in a commercial program, but in this
-     case you MUST contact me first (warp at iki.fi) and ask express permission
-     for this. I want to know what type of program it is going to be, its
-     price and so on.
-       If you are making a free program or a shareware program with just a
-     nominal price (5 US dollars or less), you don't have to ask for
-     permission.
-       In any case, I DON'T WANT MONEY for the usage of this library. It is
-     free, period.
-    .
-  3. You can make any modifications you want to it so that it conforms your
-     needs. If you make modifications to it, you have, of course, credits for
-     the modified parts.
-    .
-  4. If you use this library in your own program, you don't have to provide
-     the source code if you don't want to (ie. the source code of your program
-     or this library).
-       If you DO include the source code for this library, this text file
-     must be included in its original intact form.
-    .
-  5. If you distribute a program which uses this library, and specially if you
-     provide the source code, proper credits MUST be included. Trying to
-     obfuscate the fact that this library is not made by you or that it is
-     free is expressly prohibited. When crediting the usage of this library,
-     it's enough to include my name and email address, that is:
-     "Juha Nieminen (warp at iki.fi)". Also a URL to the library download page
-     would be nice, although not required. The official URL is:
-       http://iki.fi/warp/FunctionParser/
-    .
-  6. And the necessary "lawyer stuff":
-    .
-     The above copyright notice and this permission notice shall be
-     included in all copies or substantial portions of the Software.
-    .
-     The software is provided "as is", without warranty of any kind,
-     express or implied, including but not limited to the warranties of
-     merchantability, fitness for a particular purpose and noninfringement.
-     In no event shall the authors or copyright holders be liable for any
-     claim, damages or other liability, whether in an action of contract,
-     tort or otherwise, arising from, out of or in connection with the
-     software or the use or other dealings in the software.
+License: LGPL-2.1
+   From personal correspondence with Scott Howard, this has been licensed LGPL-2.1
+   .
+    MIME-Version: 1.0
+    Received: by 10.204.73.214 with HTTP; Mon, 31 Jan 2011 11:54:25 -0800 (PST)
+    Date: Mon, 31 Jan 2011 14:54:25 -0500
+    Delivered-To: showard314 at gmail.com
+    Message-ID: <AANLkTi=j+az1ukWMH1CxPNTyi-tuHLHfacaBy8RhGJq+ at mail.gmail.com>
+    Subject: fparser library license for LibreCAD project
+    From: Scott Howard <showard314 at gmail.com>
+    To: warp at iki.fi
+    Cc: Ries van Twisk <ries at vantwisk.nl>
+    Content-Type: text/plain; charset=ISO-8859-1
+    Content-Transfer-Encoding: quoted-printable
+    .
+    Hello,
+    .
+    LibreCAD (www.librecad.org) is a new fork of QCad, updated for qt4. It
+    is on track to be placed in Debian and Ubuntu 11.04 as the default CAD
+    program for Edubuntu. LibreCAD, however, uses version 2.51 of fparser,
+    which is not licensed under LGPL.
+    .
+    Would you be so kind as to give LibreCAD (and Debian) a license to
+    version 2.51 under LGPL (version 2 or higher, preferably)? We prefer
+    LGPL version 2.1 because it is compatible with GPL2 and GPL3 while
+    LGPL3 is only compatible with GPL3. You just have to reply to this
+    email saying you agree to the license below:
+    .
+    Thank you.
+    .
+    Cheers,
+    Scott
+    .
+    http://www.gnu.org/licenses/lgpl-2.1.txt
+    .
+                      GNU LESSER GENERAL PUBLIC LICENSE
+                           Version 2.1, February 1999
+    .
+     Copyright (C) 1991, 1999 Free Software Foundation, Inc.
+     51 Franklin Street, Fifth Floor, Boston, MA  02110-1301  USA
+     Everyone is permitted to copy and distribute verbatim copies
+     of this license document, but changing it is not allowed.
+    .
+    [This is the first released version of the Lesser GPL.  It also counts
+     as the successor of the GNU Library Public License, version 2, hence
+     the version number 2.1.]
+    .
+    [THE FULL TEXT OF THE LICENSE IS IN THE EMAIL BUT IS REMOVED FROM DEBIAN/COPYRIGHT]
+    .
+    .
+    The reply:
+    .
+    Delivered-To: showard314 at gmail.com
+    Received: by 10.204.73.214 with SMTP id r22cs31301bkj;
+            Wed, 2 Feb 2011 12:53:05 -0800 (PST)
+    Return-Path: <juha.nieminen at gmail.com>
+    Received-SPF: pass (google.com: domain of juha.nieminen at gmail.com designates 10.204.62.209 as permitted sender) client-ip=10.204.62.209;
+    Authentication-Results: mr.google.com; spf=pass (google.com: domain of juha.nieminen at gmail.com designates 10.204.62.209 as permitted sender) smtp.mail=juha.nieminen at gmail.com; dkim=pass header.i=juha.nieminen at gmail.com
+    Received: from mr.google.com ([10.204.62.209])
+            by 10.204.62.209 with SMTP id y17mr8592126bkh.98.1296679982753 (num_hops = 1);
+            Wed, 02 Feb 2011 12:53:02 -0800 (PST)
+    DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed;
+            d=gmail.com; s=gamma;
+            h=domainkey-signature:mime-version:in-reply-to:references:date
+             :message-id:subject:from:to:content-type:content-transfer-encoding;
+            bh=FZPGOHZA47DiNjMNzUDD/xai4VOCO/0AjxUeF1/vXyA=;
+            b=Kim+8NB4J1H30XcBBBvb/l8ZrbjMWJi2iZImTYVoExETsBeKvaSO5nhVc9o2CSzAEj
+             SnGXaQcNRUmy4hz6G0Ztupd8FHPrTWSWSKaWdjgG9NqF5zTDqLBZzGglPHXWvIjRKHFF
+             rZ8DlUpSEuieziCKgGywyPXpmTgZQs3wAx/wg=
+    DomainKey-Signature: a=rsa-sha1; c=nofws;
+            d=gmail.com; s=gamma;
+            h=mime-version:in-reply-to:references:date:message-id:subject:from:to
+             :content-type:content-transfer-encoding;
+            b=OBKWbszD8bC48hQxu+mn/ZjK69osC4T7F4maqrza0cGnzoHzpmUMj9E8KtjkGA8awU
+             e6fSbnbxpqDXn+94oveyP+QXnkM191PsALPIAn57uyTi7f4DpH2YSMgEnQ170odF+ueO
+             8+2oDwi9uXRn+8SQiu9V06Tu5XHdc0jOKAH5o=
+    MIME-Version: 1.0
+    Received: by 10.204.62.209 with SMTP id y17mr8592126bkh.98.1296679982711; Wed,
+     02 Feb 2011 12:53:02 -0800 (PST)
+    Received: by 10.204.69.66 with HTTP; Wed, 2 Feb 2011 12:53:02 -0800 (PST)
+    In-Reply-To: <AANLkTi=j+az1ukWMH1CxPNTyi-tuHLHfacaBy8RhGJq+ at mail.gmail.com>
+    References: <AANLkTi=j+az1ukWMH1CxPNTyi-tuHLHfacaBy8RhGJq+ at mail.gmail.com>
+    Date: Wed, 2 Feb 2011 22:53:02 +0200
+    Message-ID: <AANLkTinXLAwdNX51jU_YoJfs8DkUFeVi04xE-kabjo+L at mail.gmail.com>
+    Subject: Re: fparser library license for LibreCAD project
+    From: Juha Nieminen <juha.nieminen at gmail.com>
+    To: Scott Howard <showard314 at gmail.com>
+    Content-Type: text/plain; charset=ISO-8859-1
+    Content-Transfer-Encoding: quoted-printable
+    .
+      Yes, you have my permission to use 2.51 of the function parser
+    library under the LGPL 2 license. You can add a note to the library's
+    documentation about this.
+    .
+    .
+    .
+    This library is free software; you can redistribute it and/or
+    modify it under the terms of the GNU Lesser General Public
+    License as published by the Free Software Foundation; either
+    version 2.1 of the License, or (at your option) any later version.
+    .
+    This library 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
+    Lesser General Public License for more details.
+    .
+    You should have received a copy of the GNU Lesser General Public
+    License along with this library; if not, write to the Free Software
+    Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
+    02110-1301  USA
+    .
+    On Debian systems, the complete text of the GNU Lesser General Public License 
+    version 2.1 can be found in `/usr/share/common-licenses/LGPL-2.1'.
 
 Files: debian/*
 Copyright: 2009, Ruben Molina <rmolina at udea.edu.co>
diff --git a/debian/patches/autosave.patch b/debian/patches/autosave.patch
deleted file mode 100644
index 2af4ad6..0000000
--- a/debian/patches/autosave.patch
+++ /dev/null
@@ -1,362 +0,0 @@
-Description: enables autosave The autosave implementation doesn't clobber 
- the original user file but prepends a "#" to the filename part. Upon a 
- successful save of the user file, the autosave file will be deleted.
-Origin: http://tech.groups.yahoo.com/group/qcad-user/message/1838
-Bug: 94629
-
-Index: librecad/src/main/qc_applicationwindow.cpp
-===================================================================
---- librecad.orig/src/main/qc_applicationwindow.cpp	2010-12-04 12:46:17.000000000 -0500
-+++ librecad/src/main/qc_applicationwindow.cpp	2010-12-07 09:43:21.453428256 -0500
-@@ -165,6 +165,11 @@
- 	RS_DEBUG->print("QC_ApplicationWindow::QC_ApplicationWindow: init MDI");
-     initMDI();
- 
-+    // Activate autosave timer
-+    autosaveTimer = new QTimer(this, "autosave");
-+    connect(autosaveTimer, SIGNAL(timeout()), this, SLOT(slotFileAutoSave()));
-+    autosaveTimer->start(autosaveTime);
-+
-     // Disable menu and toolbar items
-     emit windowsChanged(FALSE);
- 
-@@ -2138,6 +2143,9 @@
-             	name = w->getDocument()->getFilename();
-             	recentFiles->add(name);
-             	w->setCaption(name);
-+		if (!autosaveTimer->isActive()) {
-+		    autosaveTimer->start(autosaveTime);
-+		}
- 	    }
-         } else {
-             // error
-@@ -2156,6 +2164,37 @@
- }
- 
- 
-+
-+/**
-+ * Autosave.
-+ */
-+void QC_ApplicationWindow::slotFileAutoSave() {
-+    RS_DEBUG->print("QC_ApplicationWindow::slotFileAutoSave()");
-+
-+    statusBar()->message(tr("Auto-saving drawing..."));
-+
-+    QC_MDIWindow* w = getMDIWindow();
-+    QString name;
-+    if (w!=NULL) {
-+	bool cancelled;
-+	if (w->slotFileSave(cancelled, true)) {
-+	    // auto-save cannot be cancelled by user, so the
-+	    // "cancelled" parameter is a dummy
-+	    statusBar()->message(tr("Auto-saved drawing"), 2000);
-+	} else {
-+	    // error
-+	    autosaveTimer->stop();
-+	    QMessageBox::information(this, QMessageBox::tr("Warning"),
-+				     tr("Cannot auto-save the file\n%1\nPlease "
-+					"check the permissions.\n"
-+					"Auto-save disabled.")
-+				     .arg(w->getDocument()->getAutoSaveFilename()),
-+				     QMessageBox::Ok);
-+	}
-+    }
-+}
-+
-+
- 
- /**
-  * Menu file -> export.
-Index: librecad/src/main/qc_applicationwindow.h
-===================================================================
---- librecad.orig/src/main/qc_applicationwindow.h	2010-12-07 09:43:04.000000000 -0500
-+++ librecad/src/main/qc_applicationwindow.h	2010-12-07 09:48:36.115406626 -0500
-@@ -37,6 +37,7 @@
- #include <qsplitter.h>
- #include <qstatusbar.h>
- #include <q3table.h>
-+#include <qtimer.h>
- #include <qtoolbar.h>
- #include <qtoolbutton.h>
- #include <q3whatsthis.h>
-@@ -145,6 +146,8 @@
-     void slotFileSave();
-     /** saves a document under a different filename*/
-     void slotFileSaveAs();
-+    /** auto-save document */
-+    void slotFileAutoSave();
- 	/** exports the document as bitmap */
- 	void slotFileExport();
- 	bool slotFileExport(const QString& name, const QString& format, 
-@@ -219,6 +222,10 @@
-     /** resizes window to 640x480 for screen shots */
-     void slotTestResize1024();
- 
-+    QTimer *autosaveTimer;
-+
-+    const static int autosaveTime = 60 * 1000;	// 1 minute
-+
- signals:
-     void gridChanged(bool on);
-     void draftChanged(bool on);
-Index: librecad/src/main/qc_mdiwindow.cpp
-===================================================================
---- librecad.orig/src/main/qc_mdiwindow.cpp	2010-12-04 12:46:17.000000000 -0500
-+++ librecad/src/main/qc_mdiwindow.cpp	2010-12-07 09:43:21.463427986 -0500
-@@ -325,23 +325,32 @@
- /**
-  * Saves the current file.
-  *
-+ * @param  isAutoSave true if this is an "autosave" operation.
-+ *                    false if this is "Save" operation requested
-+ *                    by the user.
-  * @return true if the file was saved successfully.
-  *         false if the file could not be saved or the document 
-  *         is invalid.
-  */
--bool QC_MDIWindow::slotFileSave(bool &cancelled) {
-+bool QC_MDIWindow::slotFileSave(bool &cancelled, bool isAutoSave) {
-     RS_DEBUG->print("QC_MDIWindow::slotFileSave()");
-     bool ret = false;
-     cancelled = false;
- 
-     if (document!=NULL) {
--        if (document->getFilename().isEmpty()) {
--            ret = slotFileSaveAs(cancelled);
-+	if (isAutoSave) {
-+	    // Autosave filename is always supposed to be present.
-+	    // Autosave does not change the cursor.
-+            ret = document->save(true);
-         } else {
--            QApplication::setOverrideCursor( QCursor(Qt::WaitCursor) );
--            ret = document->save();
--            QApplication::restoreOverrideCursor();
--        }
-+	    if (document->getFilename().isEmpty()) {
-+		ret = slotFileSaveAs(cancelled);
-+	    } else {
-+		QApplication::setOverrideCursor( QCursor(Qt::WaitCursor) );
-+		ret = document->save();
-+		QApplication::restoreOverrideCursor();
-+	    }
-+	}
-     }
- 
-     return ret;
-Index: librecad/src/main/qc_mdiwindow.h
-===================================================================
---- librecad.orig/src/main/qc_mdiwindow.h	2010-12-04 12:46:17.000000000 -0500
-+++ librecad/src/main/qc_mdiwindow.h	2010-12-07 09:43:21.463427986 -0500
-@@ -66,7 +66,7 @@
- 
-     void slotFileNew();
-     bool slotFileOpen(const QString& fileName, RS2::FormatType type);
--    bool slotFileSave(bool &cancelled);
-+    bool slotFileSave(bool &cancelled, bool isAutoSave=false);
-     bool slotFileSaveAs(bool &cancelled);
-     bool slotFileClose(bool force);
-     void slotFilePrint();
-Index: librecad/src/lib/engine/rs_block.cpp
-===================================================================
---- librecad.orig/src/lib/engine/rs_block.cpp	2010-12-04 12:46:17.000000000 -0500
-+++ librecad/src/lib/engine/rs_block.cpp	2010-12-07 09:43:21.463427986 -0500
-@@ -78,10 +78,10 @@
- }
- 
- 
--bool RS_Block::save() {
-+bool RS_Block::save(bool isAutoSave) {
-     RS_Graphic* g = getGraphic();
-     if (g!=NULL) {
--        return g->save();
-+        return g->save(isAutoSave);
-     } else {
-         return false;
-     }
-Index: librecad/src/lib/engine/rs_block.h
-===================================================================
---- librecad.orig/src/lib/engine/rs_block.h	2010-12-04 12:46:17.000000000 -0500
-+++ librecad/src/lib/engine/rs_block.h	2010-12-07 09:43:21.463427986 -0500
-@@ -128,7 +128,7 @@
-     /**
-      * Reimplementation from RS_Document. Saves the parent graphic document.
-      */
--    virtual bool save();
-+    virtual bool save(bool isAutoSave = false);
- 
-     /**
-      * Reimplementation from RS_Document. Does nothing.
-Index: librecad/src/lib/engine/rs_document.cpp
-===================================================================
---- librecad.orig/src/lib/engine/rs_document.cpp	2010-12-04 12:46:17.000000000 -0500
-+++ librecad/src/lib/engine/rs_document.cpp	2010-12-07 09:43:21.463427986 -0500
-@@ -40,6 +40,7 @@
-     RS_DEBUG->print("RS_Document::RS_Document() ");
- 
-     filename = "";
-+    autosaveFilename = "Unnamed";
- 	formatType = RS2::FormatUnknown;
-     setModified(false);
-     RS_Color col(RS2::FlagByLayer);
-Index: librecad/src/lib/engine/rs_document.h
-===================================================================
---- librecad.orig/src/lib/engine/rs_document.h	2010-12-04 12:46:17.000000000 -0500
-+++ librecad/src/lib/engine/rs_document.h	2010-12-07 09:43:21.463427986 -0500
-@@ -53,7 +53,7 @@
-     virtual RS_BlockList* getBlockList() = 0;
- 
-     virtual void newDoc() = 0;
--    virtual bool save() = 0;
-+    virtual bool save(bool isAutoSave = false) = 0;
-     virtual bool saveAs(const RS_String &filename, RS2::FormatType type) = 0;
-     virtual bool open(const RS_String &filename, RS2::FormatType type) = 0;
- 	
-@@ -98,6 +98,13 @@
-     }
- 	
-     /**
-+     * @return Auto-save file name of the document currently loaded.
-+     */
-+    RS_String getAutoSaveFilename() const {
-+        return autosaveFilename;
-+    }
-+	
-+    /**
-      * Sets file name for the document currently loaded.
-      */
-     void setFilename(const RS_String& fn) {
-@@ -136,6 +143,8 @@
-     RS_Pen activePen;
-     /** File name of the document or empty for a new document. */
-     RS_String filename;
-+	/** Auto-save file name of document. */
-+	RS_String autosaveFilename;
- 	/** Format type */
- 	RS2::FormatType formatType;
- };
-Index: librecad/src/lib/engine/rs_graphic.cpp
-===================================================================
---- librecad.orig/src/lib/engine/rs_graphic.cpp	2010-12-04 12:46:17.000000000 -0500
-+++ librecad/src/lib/engine/rs_graphic.cpp	2010-12-07 09:43:21.463427986 -0500
-@@ -24,6 +24,8 @@
- **
- **********************************************************************/
- 
-+#include <qfile.h>
-+#include <qfileinfo.h>
- 
- #include "rs_graphic.h"
- 
-@@ -178,21 +180,46 @@
- /**
-  * Saves this graphic with the current filename and settings.
-  */
--bool RS_Graphic::save() {
-+bool RS_Graphic::save(bool isAutoSave) {
- 
- 	bool ret = false;
-+
- 	
-     RS_DEBUG->print("RS_Graphic::save");
--    RS_DEBUG->print("  file: %s", filename.latin1());
--    RS_DEBUG->print("  format: %d", (int)formatType);
--
--    RS_DEBUG->print("  export...");
--    ret = RS_FILEIO->fileExport(*this, filename, formatType);
--
--	if (ret) {
--		setModified(false);
--		layerList.setModified(false);
--		blockList.setModified(false);
-+	if (isAutoSave && !isModified()) {
-+	    RS_DEBUG->print("  autsave and not modified => not saved");
-+		ret = true;
-+	} else {
-+		const RS_String *actualName;
-+		RS2::FormatType actualType;
-+
-+		actualType = formatType;
-+		if (isAutoSave) {
-+			actualName = new QString(autosaveFilename);
-+			if (formatType == RS2::FormatUnknown) {
-+				actualType = RS2::FormatDXF;
-+			}
-+		} else {
-+			actualName = new QString(filename);
-+		}
-+	    RS_DEBUG->print("  file: %s", actualName->latin1());
-+		RS_DEBUG->print("  format: %d", (int)actualType);
-+		RS_DEBUG->print("  export...");
-+		ret = RS_FILEIO->fileExport(*this, *actualName, actualType);
-+		delete actualName;
-+
-+		if (ret && !isAutoSave) {
-+		    setModified(false);
-+			layerList.setModified(false);
-+			blockList.setModified(false);
-+			// Remove old autosave file
-+			QFile f(autosaveFilename);
-+			if (f.exists()) {
-+				RS_DEBUG->print("  removing old autosave file %s",
-+								autosaveFilename.latin1());
-+				f.remove();
-+			}
-+		}
- 	}
- 
-     RS_DEBUG->print("RS_Graphic::save ok");
-@@ -210,9 +237,28 @@
-     RS_DEBUG->print("RS_Graphic::saveAs");
- 
-     this->filename = filename;
-+	RS_String *oldAutosaveName = new RS_String(autosaveFilename);
-+	QFileInfo finfo(filename);
-+	// Construct new autosave filename by prepending # to the filename
-+	// part, using the same directory as the destination file.
-+	this->autosaveFilename = finfo.dirPath() + "/#" + finfo.fileName();
- 	this->formatType = type;
- 
--    return save();
-+    bool ret = save();
-+
-+	if (ret) {
-+		// save was successful, remove old autosave file
-+		QFile f(*oldAutosaveName);
-+		if (f.exists()) {
-+			RS_DEBUG->print("removing old autosave file %s",
-+							oldAutosaveName->latin1());
-+			f.remove();
-+		}
-+	}
-+
-+	delete oldAutosaveName;
-+
-+	return ret;
- }
- 
- 
-@@ -226,6 +272,10 @@
- 	bool ret = false;
- 
-     this->filename = filename;
-+	QFileInfo finfo(filename);
-+	// Construct new autosave filename by prepending # to the filename
-+	// part, using the same directory as the destination file.
-+	this->autosaveFilename = finfo.dirPath() + "/#" + finfo.fileName();
- 
-     // clean all:
-     newDoc();
-Index: librecad/src/lib/engine/rs_graphic.h
-===================================================================
---- librecad.orig/src/lib/engine/rs_graphic.h	2010-12-04 12:46:17.000000000 -0500
-+++ librecad/src/lib/engine/rs_graphic.h	2010-12-07 09:43:21.463427986 -0500
-@@ -69,7 +69,7 @@
-     }
- 
-     virtual void newDoc();
--    virtual bool save();
-+    virtual bool save(bool isAutoSave = false);
-     virtual bool saveAs(const RS_String& filename, RS2::FormatType type);
-     virtual bool open(const RS_String& filename, RS2::FormatType type);
- 	
diff --git a/debian/patches/series b/debian/patches/series
index f03c88c..4cf4dc4 100644
--- a/debian/patches/series
+++ b/debian/patches/series
@@ -1,4 +1,3 @@
 rs_debug.patch
 bug#234340.patch
 qcad-2.0.5.0-latin2.patch
-# autosave.patch
diff --git a/debian/rules b/debian/rules
index 09ab98f..060cd0e 100755
--- a/debian/rules
+++ b/debian/rules
@@ -4,12 +4,12 @@
 # export DH_VERBOSE=1
 
 %:
-	dh $@
+	dh $@ --parallel
 
 override_dh_clean:
 	dh_clean
 	rm -rf unix/
-	find . -name *.qm -print0 | xargs -0 rm -rf
+	find . -name *.qm -delete
 
 REVISION=106
 VERSION=1.0.0~beta5

-- 
2D CAD system



More information about the debian-science-commits mailing list