install headers; refs #119

master
Marc Wäckerlin 13 years ago
parent b7279a5eab
commit aecd32ca6a
  1. 13
      src/browser.hxx
  2. 6
      src/main.cxx
  3. 2
      src/makefile.am
  4. 2
      src/swissbrowser_de.ts
  5. 2
      src/swissbrowser_en.ts
  6. 2
      src/swissbrowser_fr.ts
  7. 2
      src/swissbrowser_it.ts

@ -262,6 +262,7 @@ class Browser: public QMainWindow, protected Ui::Browser {
return browser; return browser;
} }
protected: protected:
void closeEvent(QCloseEvent *event) { void closeEvent(QCloseEvent *event) {
@ -273,6 +274,14 @@ class Browser: public QMainWindow, protected Ui::Browser {
QApplication::exit(0); QApplication::exit(0);
} }
public Q_SLOTS:
void on_actionEditBookmarks_triggered() {
_editbookmarks->show();
}
private Q_SLOTS: private Q_SLOTS:
void load() { void load() {
@ -602,10 +611,6 @@ class Browser: public QMainWindow, protected Ui::Browser {
} }
} }
void on_actionEditBookmarks_triggered() {
_editbookmarks->show();
}
void zoom(int i) { void zoom(int i) {
LOG<<i; LOG<<i;
statusBar()->showMessage(tr("Zoom: %1%").arg(i)); statusBar()->showMessage(tr("Zoom: %1%").arg(i));

@ -334,6 +334,7 @@ int main(int argv, char** argc) try {
bool login(false); bool login(false);
Settings::MimeTypes mimetypes; Settings::MimeTypes mimetypes;
QString bookmarks; QString bookmarks;
bool editbookmarks(false);
QStringList args(app.arguments()); QStringList args(app.arguments());
std::auto_ptr<QSettings> settings std::auto_ptr<QSettings> settings
(std::auto_ptr<QSettings>(new QSettings("SwissSign", "SwissBrowser"))); (std::auto_ptr<QSettings>(new QSettings("SwissSign", "SwissBrowser")));
@ -359,6 +360,8 @@ int main(int argv, char** argc) try {
" start <tool> for mimetype <mime>\n" " start <tool> for mimetype <mime>\n"
" -b, --bookmarks <file>\n" " -b, --bookmarks <file>\n"
" load and save bookmarks from and to <file>\n" " load and save bookmarks from and to <file>\n"
" -e, --edit-bookmarks\n"
" start in bookmark-edition mode\n"
" <url> optional full URL\n" " <url> optional full URL\n"
"Environment:\n" "Environment:\n"
" LANGUAGE \"de\", \"en\", ... (actual: %5)\n" " LANGUAGE \"de\", \"en\", ... (actual: %5)\n"
@ -387,6 +390,8 @@ int main(int argv, char** argc) try {
actlib = *it; actlib = *it;
} else if ((*it=="-b" || *it=="--bookmarks") && ++it!=args.end()) { } else if ((*it=="-b" || *it=="--bookmarks") && ++it!=args.end()) {
bookmarks = *it; bookmarks = *it;
} else if ((*it=="-e" || *it=="--edit-bookmarks")) {
editbookmarks = true;
} else if ((*it=="-s" || *it=="--settings") && ++it!=args.end()) { } else if ((*it=="-s" || *it=="--settings") && ++it!=args.end()) {
settings = std::auto_ptr<QSettings> settings = std::auto_ptr<QSettings>
(new QSettings(*it, QSettings::IniFormat)); (new QSettings(*it, QSettings::IniFormat));
@ -433,6 +438,7 @@ int main(int argv, char** argc) try {
if (env.contains("QTWEBKIT_PLUGIN_PATH")) qt_drt_overwritePluginDirectories(); if (env.contains("QTWEBKIT_PLUGIN_PATH")) qt_drt_overwritePluginDirectories();
Browser browser(actlib, urls, settings.get(), mimetypes, silent, Browser browser(actlib, urls, settings.get(), mimetypes, silent,
login, quirks, bookmarks); login, quirks, bookmarks);
if (editbookmarks) browser.on_actionEditBookmarks_triggered();
return app.exec(); return app.exec();
} catch (std::exception& x) { } catch (std::exception& x) {
std::cerr<<"**** Error: "<<x.what()<<std::endl; std::cerr<<"**** Error: "<<x.what()<<std::endl;

@ -7,7 +7,7 @@
SUBDIRS = qbrowserlib designer SUBDIRS = qbrowserlib designer
#include_HEADERS = @srcdir@/qbrowserlib/*.hxx include_HEADERS = @srcdir@/qbrowserlib/*.hxx
if !MINGW32 if !MINGW32
if MAC if MAC

@ -732,6 +732,8 @@ Options:
start &lt;tool&gt; for mimetype &lt;mime&gt; start &lt;tool&gt; for mimetype &lt;mime&gt;
-b, --bookmarks &lt;file&gt; -b, --bookmarks &lt;file&gt;
load and save bookmarks from and to &lt;file&gt; load and save bookmarks from and to &lt;file&gt;
-e, --edit-bookmarks
start in bookmark-edition mode
&lt;url&gt; optional full URL &lt;url&gt; optional full URL
Environment: Environment:
LANGUAGE &quot;de&quot;, &quot;en&quot;, ... (actual: %5) LANGUAGE &quot;de&quot;, &quot;en&quot;, ... (actual: %5)

@ -732,6 +732,8 @@ Options:
start &lt;tool&gt; for mimetype &lt;mime&gt; start &lt;tool&gt; for mimetype &lt;mime&gt;
-b, --bookmarks &lt;file&gt; -b, --bookmarks &lt;file&gt;
load and save bookmarks from and to &lt;file&gt; load and save bookmarks from and to &lt;file&gt;
-e, --edit-bookmarks
start in bookmark-edition mode
&lt;url&gt; optional full URL &lt;url&gt; optional full URL
Environment: Environment:
LANGUAGE &quot;de&quot;, &quot;en&quot;, ... (actual: %5) LANGUAGE &quot;de&quot;, &quot;en&quot;, ... (actual: %5)

@ -732,6 +732,8 @@ Options:
start &lt;tool&gt; for mimetype &lt;mime&gt; start &lt;tool&gt; for mimetype &lt;mime&gt;
-b, --bookmarks &lt;file&gt; -b, --bookmarks &lt;file&gt;
load and save bookmarks from and to &lt;file&gt; load and save bookmarks from and to &lt;file&gt;
-e, --edit-bookmarks
start in bookmark-edition mode
&lt;url&gt; optional full URL &lt;url&gt; optional full URL
Environment: Environment:
LANGUAGE &quot;de&quot;, &quot;en&quot;, ... (actual: %5) LANGUAGE &quot;de&quot;, &quot;en&quot;, ... (actual: %5)

@ -732,6 +732,8 @@ Options:
start &lt;tool&gt; for mimetype &lt;mime&gt; start &lt;tool&gt; for mimetype &lt;mime&gt;
-b, --bookmarks &lt;file&gt; -b, --bookmarks &lt;file&gt;
load and save bookmarks from and to &lt;file&gt; load and save bookmarks from and to &lt;file&gt;
-e, --edit-bookmarks
start in bookmark-edition mode
&lt;url&gt; optional full URL &lt;url&gt; optional full URL
Environment: Environment:
LANGUAGE &quot;de&quot;, &quot;en&quot;, ... (actual: %5) LANGUAGE &quot;de&quot;, &quot;en&quot;, ... (actual: %5)

Loading…
Cancel
Save