update scripts to reflect latest api changes
This commit is contained in:
@@ -32,7 +32,6 @@ local rate = 0
|
||||
function on_alarm()
|
||||
date = os.date("%Y-%m-%d")
|
||||
get_rates(date)
|
||||
ui:prepare_context_menu({{"share-alt","Поделиться"},{"copy","Копировать"},{"redo","Перезагрузить"}})
|
||||
end
|
||||
|
||||
function get_rates(date)
|
||||
@@ -78,6 +77,16 @@ function on_click(idx)
|
||||
end
|
||||
end
|
||||
|
||||
function on_long_click(idx)
|
||||
item_idx = idx
|
||||
|
||||
ui:show_context_menu({
|
||||
{"share-alt","Поделиться"},
|
||||
{"copy","Копировать"},
|
||||
{"redo","Перезагрузить"}
|
||||
})
|
||||
end
|
||||
|
||||
function on_dialog_action(data)
|
||||
if data == -1 then
|
||||
return
|
||||
@@ -131,7 +140,7 @@ function on_dialog_action(data)
|
||||
get_rates(date)
|
||||
end
|
||||
|
||||
function on_context_menu_click(item_idx, menu_idx)
|
||||
function on_context_menu_click(menu_idx)
|
||||
if menu_idx == 2 then
|
||||
system:copy_to_clipboard(rate)
|
||||
elseif menu_idx == 1 then
|
||||
|
||||
Reference in New Issue
Block a user