mirror of
https://github.com/Pathduck/gallery3.git
synced 2026-07-11 01:33:51 -04:00
Create a new thumb_menu() and convert Digibug over to use it.
1) Eliminate digibug_album.html 2) Get rid of the $(document).ready() in digibug.js and rename popUp() to digibug_popup() then just make direct calls to digibug_popup() in the menu urls.
This commit is contained in:
@@ -121,16 +121,20 @@ class Theme_View_Core extends View {
|
||||
$this->_menu("photo");
|
||||
}
|
||||
|
||||
private function _menu($type) {
|
||||
public function thumb_menu($item) {
|
||||
$this->_menu("thumb", $item);
|
||||
}
|
||||
|
||||
private function _menu($type, $item=null) {
|
||||
$menu = Menu::factory("root");
|
||||
call_user_func_array(array("gallery_menu", $type), array(&$menu, $this));
|
||||
call_user_func_array(array("gallery_menu", $type), array(&$menu, $this, $item));
|
||||
foreach (module::active() as $module) {
|
||||
if ($module->name == "gallery") {
|
||||
continue;
|
||||
}
|
||||
$class = "{$module->name}_menu";
|
||||
if (method_exists($class, $type)) {
|
||||
call_user_func_array(array($class, $type), array(&$menu, $this));
|
||||
call_user_func_array(array($class, $type), array(&$menu, $this, $item));
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user