Skip to content

Commit

Permalink
reread current directory files after unplug from PC
Browse files Browse the repository at this point in the history
  • Loading branch information
houqp committed Jun 7, 2012
1 parent 2485a55 commit 0558a5e
Showing 1 changed file with 6 additions and 4 deletions.
10 changes: 6 additions & 4 deletions commands.lua
Original file line number Diff line number Diff line change
Expand Up @@ -191,8 +191,8 @@ function Commands:new(obj)
G_screen_saver_mode = false
end
)
obj:add(KEY_CHARGING, nil, nil,
"",
obj:add(KEY_CHARGING, nil, "plugin/out usb",
"toggle usb drive mode",
function()
--os.execute("echo 'usb in' >> /mnt/us/event_test.txt")
if G_charging_mode == false and G_screen_saver_mode == false then
Expand All @@ -206,8 +206,8 @@ function Commands:new(obj)
G_charging_mode = true
end
)
obj:add(KEY_NOT_CHARGING, nil, nil,
"",
obj:add(KEY_NOT_CHARGING, nil, "plugin/out usb",
"toggle usb drive mode",
function()
--os.execute("echo 'usb out' >> /mnt/us/event_test.txt")
if G_charging_mode == true and G_screen_saver_mode == false then
Expand All @@ -217,6 +217,8 @@ function Commands:new(obj)
Screen:restoreFromSavedBB()
fb:refresh(0)
end
FileChooser:setPath(FileChooser.path)
FileChooser.pagedirty = true
G_charging_mode = false
end
)
Expand Down

0 comments on commit 0558a5e

Please sign in to comment.