1
0
mirror of git://projects.qi-hardware.com/openwrt-packages.git synced 2024-11-23 07:04:05 +02:00
openwrt-packages/gmenu2x/patches/001-filedialog.patch

41 lines
1.3 KiB
Diff
Raw Normal View History

2010-08-03 15:11:28 +03:00
--- gmenu2x/src/filedialog.cpp 2010-08-03 12:18:26.000000000 +0200
2010-08-03 16:31:50 +03:00
+++ gmenu2xm/src/filedialog.cpp 2010-08-03 15:08:13.000000000 +0200
2010-08-03 15:11:28 +03:00
@@ -35,7 +35,7 @@
this->text = text;
this->filter = filter;
this->file = "";
- setPath("/card");
+ setPath("/");
title = "File Browser";
if (!file.empty()) {
string::size_type pos = file.rfind("/");
@@ -50,7 +50,7 @@
bool FileDialog::exec() {
bool close = false, result = true, ts_pressed = false;
if (!fileExists(path()))
- setPath("/card");
+ setPath("/");
fl.setFilter(filter);
fl.browse();
@@ -155,7 +155,7 @@
} break;
case FD_ACTION_GOUP: {
string::size_type p = path().rfind("/");
- if (p==string::npos || path().substr(0,11)!="/card" || p<4)
2010-08-03 16:31:50 +03:00
+ if (p==string::npos)
2010-08-03 15:11:28 +03:00
return false;
else
setPath( path().substr(0,p) );
--- gmenu2x/src/gmenu2x.cpp 2010-08-03 13:55:31.000000000 +0200
+++ gmenu2xm/src/gmenu2x.cpp 2010-08-03 13:55:50.000000000 +0200
@@ -998,7 +998,7 @@
}
void GMenu2X::explorer() {
- FileDialog fd(this,tr["Select an application"],".gpu,.dge,.sh");
+ FileDialog fd(this,tr["Select an application"],".gpu,.dge,.sh,");
if (fd.exec()) {
if (confInt["saveSelection"] && (confInt["section"]!=menu->selSectionIndex() || confInt["link"]!=menu->selLinkIndex()))
writeConfig();