Update Google search widget

This commit is contained in:
Evgeny
2024-09-21 10:26:52 +03:00
parent 71bb976fb6
commit 1580867d31

View File

@@ -2,7 +2,7 @@
-- description = "AIO wrapper for the Google search app widget - open widget settings for options" -- description = "AIO wrapper for the Google search app widget - open widget settings for options"
-- type = "widget" -- type = "widget"
-- author = "Theodor Galanis (t.me/TheodorGalanis)" -- author = "Theodor Galanis (t.me/TheodorGalanis)"
-- version = "2.5" -- version = "2.6"
-- foldable = "false" -- foldable = "false"
-- uses_app: "com.google.android.googlequicksearchbox" -- uses_app: "com.google.android.googlequicksearchbox"
@@ -50,10 +50,10 @@ elseif idx == indices[2] then
elseif idx == indices[3] then elseif idx == indices[3] then
w_bridge:click("image_7") w_bridge:click("image_7")
elseif idx == indices[4] then elseif idx == indices[4] then
w_bridge:click("image_9") w_bridge:click("image_11")
elseif idx == indices[5] then elseif idx == indices[5] then
w_bridge:click("image_10") w_bridge:click("image_12")
else return else return
end end
end end
@@ -70,7 +70,7 @@ ui:show_toast("Google weather")
elseif idx == indices[3] then elseif idx == indices[3] then
ui:show_toast("Google discover") ui:show_toast("Google discover")
elseif idx == indices[4] then elseif idx == indices[4] then
ui:show_toast("Google voice search") ui:show_toast("Google voice search")
elseif idx == indices[5] then elseif idx == indices[5] then
ui:show_toast("Google Lens") ui:show_toast("Google Lens")
end end
@@ -86,7 +86,7 @@ end
function setup_app_widget() function setup_app_widget()
local id = widgets:setup("com.google.android.googlequicksearchbox/com.google.android.googlequicksearchbox.SearchWidgetProvider") local id = widgets:setup("com.google.android.googlequicksearchbox/com.google.android.googlequicksearchbox.SearchWidgetProvider")
if (id ~= nil) then if (id ~= nil) then
prefs.wid = id prefs.wid = id
else else
@@ -125,4 +125,4 @@ tab.category = "MAIN"
tab.package = "com.google.android.googlequicksearchbox" tab.package = "com.google.android.googlequicksearchbox"
tab.component = "com.google.android.googlequicksearchbox/com.google.android.apps.search.weather.WeatherExportedActivity" tab.component = "com.google.android.googlequicksearchbox/com.google.android.apps.search.weather.WeatherExportedActivity"
return tab return tab
end end