7 Module implementing the bookmarks manager. |
7 Module implementing the bookmarks manager. |
8 """ |
8 """ |
9 |
9 |
10 import os |
10 import os |
11 |
11 |
12 from PyQt4.QtCore import * |
12 from PyQt4.QtCore import pyqtSignal, Qt, QT_TRANSLATE_NOOP, QObject, QFile, QByteArray, \ |
13 from PyQt4.QtGui import * |
13 QBuffer, QIODevice, QXmlStreamReader, QDate, QFileInfo, QUrl |
|
14 from PyQt4.QtGui import QUndoStack, QUndoCommand, QApplication |
14 from PyQt4.QtWebKit import QWebPage |
15 from PyQt4.QtWebKit import QWebPage |
15 |
16 |
16 from E5Gui import E5MessageBox, E5FileDialog |
17 from E5Gui import E5MessageBox, E5FileDialog |
17 |
18 |
18 from .BookmarkNode import BookmarkNode |
19 from .BookmarkNode import BookmarkNode |
400 writer = XbelWriter() |
401 writer = XbelWriter() |
401 if not writer.write(fileName, self.__bookmarkRootNode): |
402 if not writer.write(fileName, self.__bookmarkRootNode): |
402 E5MessageBox.critical(None, |
403 E5MessageBox.critical(None, |
403 self.trUtf8("Exporting Bookmarks"), |
404 self.trUtf8("Exporting Bookmarks"), |
404 self.trUtf8("""Error exporting bookmarks to <b>{0}</b>.""")\ |
405 self.trUtf8("""Error exporting bookmarks to <b>{0}</b>.""")\ |
405 .format(bookmarkFile)) |
406 .format(fileName)) |
406 |
407 |
407 def __convertFromOldBookmarks(self): |
408 def __convertFromOldBookmarks(self): |
408 """ |
409 """ |
409 Private method to convert the old bookmarks into the new ones. |
410 Private method to convert the old bookmarks into the new ones. |
410 """ |
411 """ |