|
a/src/qtgui/restable.cpp |
|
b/src/qtgui/restable.cpp |
|
... |
|
... |
46 |
#include "plaintorich.h"
|
46 |
#include "plaintorich.h"
|
47 |
#include "indexer.h"
|
47 |
#include "indexer.h"
|
48 |
#include "respopup.h"
|
48 |
#include "respopup.h"
|
49 |
#include "rclmain_w.h"
|
49 |
#include "rclmain_w.h"
|
50 |
#include "multisave.h"
|
50 |
#include "multisave.h"
|
|
|
51 |
#include "appformime.h"
|
51 |
|
52 |
|
52 |
static const QKeySequence quitKeySeq("Ctrl+q");
|
53 |
static const QKeySequence quitKeySeq("Ctrl+q");
|
53 |
static const QKeySequence closeKeySeq("Ctrl+w");
|
54 |
static const QKeySequence closeKeySeq("Ctrl+w");
|
54 |
|
55 |
|
55 |
// Compensate for the default and somewhat bizarre vertical placement
|
56 |
// Compensate for the default and somewhat bizarre vertical placement
|
|
... |
|
... |
779 |
emit docPreviewClicked(i, m_detaildoc, 0);
|
780 |
emit docPreviewClicked(i, m_detaildoc, 0);
|
780 |
else
|
781 |
else
|
781 |
emit editRequested(m_detaildoc);
|
782 |
emit editRequested(m_detaildoc);
|
782 |
}
|
783 |
}
|
783 |
break;
|
784 |
break;
|
|
|
785 |
|
|
|
786 |
// Run script. Link format Rnn|Script Name
|
|
|
787 |
case 'R':
|
|
|
788 |
{
|
|
|
789 |
int bar = s.indexOf("|");
|
|
|
790 |
if (bar == -1 || bar >= s.size()-1)
|
|
|
791 |
break;
|
|
|
792 |
string cmdname = qs2utf8s(s.right(s.size() - (bar + 1)));
|
|
|
793 |
DesktopDb ddb(path_cat(theconfig->getConfDir(), "scripts"));
|
|
|
794 |
DesktopDb::AppDef app;
|
|
|
795 |
if (ddb.appByName(cmdname, app)) {
|
|
|
796 |
QAction act(QString::fromUtf8(app.name.c_str()), this);
|
|
|
797 |
QVariant v(QString::fromUtf8(app.command.c_str()));
|
|
|
798 |
act.setData(v);
|
|
|
799 |
menuOpenWith(&act);
|
|
|
800 |
}
|
|
|
801 |
}
|
|
|
802 |
break;
|
|
|
803 |
|
784 |
default:
|
804 |
default:
|
785 |
LOGERR(("ResTable::linkWasClicked: bad link [%s]\n", ascurl));
|
805 |
LOGERR(("ResTable::linkWasClicked: bad link [%s]\n", ascurl));
|
786 |
break;// ??
|
806 |
break;// ??
|
787 |
}
|
807 |
}
|
788 |
}
|
808 |
}
|