diff --git a/README b/README index a85f568..d8499fb 100644 --- a/README +++ b/README @@ -78,7 +78,7 @@ Restart suspended widgets: - if widget is provided only that widget will be activated Enable caching for a widget: - vicious.enable_caching(widget_type) + vicious.cache(widget_type) - enable caching of values returned by a widget type @@ -335,7 +335,7 @@ Date widget Memory widget memwidget = widget({ type = 'textbox' }) - vicious.enable_caching(vicious.widgets.mem) + vicious.cache(vicious.widgets.mem) vicious.register(memwidget, vicious.widgets.mem, '$1 ($2MB/$3MB)', 13) - updated every 13 seconds, appends "MB" to 2nd and 3rd returned diff --git a/init.lua b/init.lua index 0f41ef3..7798edf 100644 --- a/init.lua +++ b/init.lua @@ -207,7 +207,7 @@ end -- }}} -- {{{ Enable caching for a widget -function enable_caching(widget) +function cache(widget) if widget_cache[widget] == nil then widget_cache[widget] = {} end