From f7a720d2e827925f6fbae4981e2a17fd79eb31f6 Mon Sep 17 00:00:00 2001 From: Bharat Mediratta Date: Mon, 8 Jun 2009 23:17:28 -0700 Subject: Rename main_element_attributes() callback to body_attributes() to be more intuitive for themers. --- themes/admin_default/views/admin.html.php | 2 +- themes/default/views/page.html.php | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) (limited to 'themes') diff --git a/themes/admin_default/views/admin.html.php b/themes/admin_default/views/admin.html.php index 721c4dd5..b7cfaa40 100644 --- a/themes/admin_default/views/admin.html.php +++ b/themes/admin_default/views/admin.html.php @@ -31,7 +31,7 @@ admin_head() ?> - main_element_attributes() ?>> + body_attributes() ?>> admin_page_top() ?>
diff --git a/themes/default/views/page.html.php b/themes/default/views/page.html.php index 6c77fb72..0c84129f 100644 --- a/themes/default/views/page.html.php +++ b/themes/default/views/page.html.php @@ -54,7 +54,7 @@ head() ?> - main_element_attributes() ?>> + body_attributes() ?>> page_top() ?>
site_status() ?> -- cgit v1.2.3 From 3c3a65b5a76c2cb53fe143f2b89d767b36dcafa2 Mon Sep 17 00:00:00 2001 From: Tim Almdal Date: Tue, 9 Jun 2009 22:18:41 +0800 Subject: Rather than just displaying the "unformatted" login screen when the root album is not viewable by a guest, display the root album as if it was empty. When the page finishes loading force the login dialog to be displayed. Signed-off-by: Tim Almdal --- modules/gallery/controllers/albums.php | 12 ++++++++++-- themes/default/views/page.html.php | 7 +++++++ 2 files changed, 17 insertions(+), 2 deletions(-) (limited to 'themes') diff --git a/modules/gallery/controllers/albums.php b/modules/gallery/controllers/albums.php index efde4f09..0fd89f05 100644 --- a/modules/gallery/controllers/albums.php +++ b/modules/gallery/controllers/albums.php @@ -23,16 +23,24 @@ class Albums_Controller extends Items_Controller { * @see REST_Controller::_show($resource) */ public function _show($album) { + $page_size = module::get_var("gallery", "page_size", 9); if (!access::can("view", $album)) { if ($album->id == 1) { - print new Theme_View("login_page.html", "album"); + $template = new Theme_View("page.html", "album"); + $template->set_global("page_size", $page_size); + $template->set_global("item", $album); + $template->set_global("children", array()); + $template->set_global("children_count", 0); + $template->set_global("parents", $album->parents()); + $template->unauthorized = true; + $template->content = new View("album.html"); + print $template; return; } else { access::forbidden(); } } - $page_size = module::get_var("gallery", "page_size", 9); $show = $this->input->get("show"); if ($show) { diff --git a/themes/default/views/page.html.php b/themes/default/views/page.html.php index 6c77fb72..a17b643d 100644 --- a/themes/default/views/page.html.php +++ b/themes/default/views/page.html.php @@ -52,6 +52,13 @@ head() ?> + + + main_element_attributes() ?>> -- cgit v1.2.3 From a4a38ba76003f5ca8fec0f50b4a84b930c80dd20 Mon Sep 17 00:00:00 2001 From: Tim Almdal Date: Wed, 10 Jun 2009 08:17:27 +0800 Subject: Created not_authorized.html.php which is a prettier login screen if the root album is not publicly browsable. Signed-off-by: Tim Almdal --- modules/gallery/controllers/albums.php | 10 ++-------- themes/default/views/page.html.php | 7 ------- 2 files changed, 2 insertions(+), 15 deletions(-) (limited to 'themes') diff --git a/modules/gallery/controllers/albums.php b/modules/gallery/controllers/albums.php index 0fd89f05..9b837442 100644 --- a/modules/gallery/controllers/albums.php +++ b/modules/gallery/controllers/albums.php @@ -26,14 +26,8 @@ class Albums_Controller extends Items_Controller { $page_size = module::get_var("gallery", "page_size", 9); if (!access::can("view", $album)) { if ($album->id == 1) { - $template = new Theme_View("page.html", "album"); - $template->set_global("page_size", $page_size); - $template->set_global("item", $album); - $template->set_global("children", array()); - $template->set_global("children_count", 0); - $template->set_global("parents", $album->parents()); - $template->unauthorized = true; - $template->content = new View("album.html"); + $template = new Theme_View("not_authorized.html", "album"); + $template->content = new View("login_page.html"); print $template; return; } else { diff --git a/themes/default/views/page.html.php b/themes/default/views/page.html.php index a17b643d..6c77fb72 100644 --- a/themes/default/views/page.html.php +++ b/themes/default/views/page.html.php @@ -52,13 +52,6 @@ head() ?> - - - main_element_attributes() ?>> -- cgit v1.2.3 From 98422857ebd5bd5c68b7b0060b6f6aef0b74bcbc Mon Sep 17 00:00:00 2001 From: Tim Almdal Date: Wed, 10 Jun 2009 08:22:35 +0800 Subject: Forgot this on the last commit Signed-off-by: Tim Almdal --- themes/default/views/not_authorized.html.php | 69 ++++++++++++++++++++++++++++ 1 file changed, 69 insertions(+) create mode 100644 themes/default/views/not_authorized.html.php (limited to 'themes') diff --git a/themes/default/views/not_authorized.html.php b/themes/default/views/not_authorized.html.php new file mode 100644 index 00000000..d009a4ac --- /dev/null +++ b/themes/default/views/not_authorized.html.php @@ -0,0 +1,69 @@ + + + + + + + <? if (empty($page_title)): ?> + <?= t("Gallery3 Login") ?> + <? if (!empty($item)): ?> + :: <?= p::clean($item->title) ?> + <? endif ?> + <? else: ?> + <?= $page_title ?> + <? endif ?> + <?= $theme->page_type ?> + + " type="image/x-icon" /> + " + media="screen,print,projection" /> + " + media="screen" /> + " + media="screen,print,projection" /> + " + media="screen,print,projection" /> + + + + + + + + + + + + head() ?> + + + main_element_attributes() ?>> + page_top() ?> +
+ site_status() ?> +
+ display("header.html") ?> +
+
+
+
+
+ messages() ?> + +
+
+
+
+
+
+
+ display("footer.html") ?> +
+
+ page_bottom() ?> + + -- cgit v1.2.3 From b276eaa68beca1266bf8fd83625ddfad73f44420 Mon Sep 17 00:00:00 2001 From: Tim Almdal Date: Wed, 10 Jun 2009 08:38:21 +0800 Subject: Add some window dressing to login_page.html in order to make it more in line with the overall look of the Gallery3 theme Signed-off-by: Tim Almdal --- modules/gallery/controllers/albums.php | 4 +- themes/default/views/login_page.html.php | 48 ++++++++++++++++++- themes/default/views/not_authorized.html.php | 69 ---------------------------- 3 files changed, 47 insertions(+), 74 deletions(-) delete mode 100644 themes/default/views/not_authorized.html.php (limited to 'themes') diff --git a/modules/gallery/controllers/albums.php b/modules/gallery/controllers/albums.php index 9b837442..f37609e6 100644 --- a/modules/gallery/controllers/albums.php +++ b/modules/gallery/controllers/albums.php @@ -26,9 +26,7 @@ class Albums_Controller extends Items_Controller { $page_size = module::get_var("gallery", "page_size", 9); if (!access::can("view", $album)) { if ($album->id == 1) { - $template = new Theme_View("not_authorized.html", "album"); - $template->content = new View("login_page.html"); - print $template; + print new Theme_View("login_page.html"); return; } else { access::forbidden(); diff --git a/themes/default/views/login_page.html.php b/themes/default/views/login_page.html.php index 27f8571e..c4880727 100644 --- a/themes/default/views/login_page.html.php +++ b/themes/default/views/login_page.html.php @@ -7,11 +7,55 @@ <?= t("Please Login to Gallery") ?> + " type="image/x-icon" /> + " + media="screen,print,projection" /> + " + media="screen" /> + " + media="screen,print,projection" /> " media="screen,print,projection" /> + + + + + + + + + + + + head() ?> - - + main_element_attributes() ?>> + page_top() ?> +
+ site_status() ?> +
+ display("header.html") ?> +
+
+
+
+
+ messages() ?> + +
+
+
+
+
+
+
+ display("footer.html") ?> +
+
+ page_bottom() ?> diff --git a/themes/default/views/not_authorized.html.php b/themes/default/views/not_authorized.html.php deleted file mode 100644 index d009a4ac..00000000 --- a/themes/default/views/not_authorized.html.php +++ /dev/null @@ -1,69 +0,0 @@ - - - - - - - <? if (empty($page_title)): ?> - <?= t("Gallery3 Login") ?> - <? if (!empty($item)): ?> - :: <?= p::clean($item->title) ?> - <? endif ?> - <? else: ?> - <?= $page_title ?> - <? endif ?> - <?= $theme->page_type ?> - - " type="image/x-icon" /> - " - media="screen,print,projection" /> - " - media="screen" /> - " - media="screen,print,projection" /> - " - media="screen,print,projection" /> - - - - - - - - - - - - head() ?> - - - main_element_attributes() ?>> - page_top() ?> -
- site_status() ?> -
- display("header.html") ?> -
-
-
-
-
- messages() ?> - -
-
-
-
-
-
-
- display("footer.html") ?> -
-
- page_bottom() ?> - - -- cgit v1.2.3 From 798444f40bbc0344568e9744abf7034b9a59febd Mon Sep 17 00:00:00 2001 From: Bharat Mediratta Date: Tue, 9 Jun 2009 19:45:15 -0700 Subject: Replace login_page.html.php with the form, wrapped in our default page type. --- modules/gallery/controllers/albums.php | 4 ++- themes/default/views/login_page.html.php | 61 -------------------------------- 2 files changed, 3 insertions(+), 62 deletions(-) delete mode 100644 themes/default/views/login_page.html.php (limited to 'themes') diff --git a/modules/gallery/controllers/albums.php b/modules/gallery/controllers/albums.php index f37609e6..34fee917 100644 --- a/modules/gallery/controllers/albums.php +++ b/modules/gallery/controllers/albums.php @@ -26,7 +26,9 @@ class Albums_Controller extends Items_Controller { $page_size = module::get_var("gallery", "page_size", 9); if (!access::can("view", $album)) { if ($album->id == 1) { - print new Theme_View("login_page.html"); + $view = new Theme_View("page.html", "page"); + $view->content = user::get_login_form("login/auth_html"); + print $view; return; } else { access::forbidden(); diff --git a/themes/default/views/login_page.html.php b/themes/default/views/login_page.html.php deleted file mode 100644 index c4880727..00000000 --- a/themes/default/views/login_page.html.php +++ /dev/null @@ -1,61 +0,0 @@ - - - - - - - <?= t("Please Login to Gallery") ?> - - " type="image/x-icon" /> - " - media="screen,print,projection" /> - " - media="screen" /> - " - media="screen,print,projection" /> - " - media="screen,print,projection" /> - - - - - - - - - - - - head() ?> - - - main_element_attributes() ?>> - page_top() ?> -
- site_status() ?> -
- display("header.html") ?> -
-
-
-
-
- messages() ?> - -
-
-
-
-
-
-
- display("footer.html") ?> -
-
- page_bottom() ?> - - -- cgit v1.2.3 From f1c91ab9779542f1605476bc52c57d5f14294e97 Mon Sep 17 00:00:00 2001 From: jhilden Date: Tue, 9 Jun 2009 23:54:02 -0400 Subject: fixed that you couldn't copy and paste text from the admin dashboard * made only the block headers draggable, so that the rest of the block could be normal * this should fix bug #292 --- modules/gallery/views/admin_dashboard.html.php | 8 ++++---- themes/admin_default/css/screen.css | 3 +-- 2 files changed, 5 insertions(+), 6 deletions(-) (limited to 'themes') diff --git a/modules/gallery/views/admin_dashboard.html.php b/modules/gallery/views/admin_dashboard.html.php index c266d7e1..5b8cae2e 100644 --- a/modules/gallery/views/admin_dashboard.html.php +++ b/modules/gallery/views/admin_dashboard.html.php @@ -10,23 +10,23 @@ }; $(document).ready(function(){ - $("#gAdminDashboard .gBlock *:first").addClass("gDraggable"); + $("#gAdminDashboard .gBlock .ui-widget-header").addClass("gDraggable"); $("#gAdminDashboard").sortable({ connectWith: ["#gAdminDashboardSidebar"], containment: "document", cursor: "move", - handle: $("div:first"), + handle: $(".ui-widget-header"), opacity: 0.6, placeholder: "gDropTarget", stop: update_blocks }); - $("#gAdminDashboardSidebar .gBlock *:first").addClass("gDraggable"); + $("#gAdminDashboardSidebar .gBlock .ui-widget-header").addClass("gDraggable"); $("#gAdminDashboardSidebar").sortable({ connectWith: ["#gAdminDashboard"], containment: "document", cursor: "move", - handle: $("div:first"), + handle: $(".ui-widget-header"), opacity: 0.6, placeholder: "gDropTarget", stop: update_blocks diff --git a/themes/admin_default/css/screen.css b/themes/admin_default/css/screen.css index 1ad64fa1..82f85f21 100644 --- a/themes/admin_default/css/screen.css +++ b/themes/admin_default/css/screen.css @@ -327,8 +327,7 @@ li.gDefaultGroup h4, li.gDefaultGroup .gUser { border: none; } -.ui-draggable, -.ui-sortable { +.ui-draggable { cursor: move; } -- cgit v1.2.3 From d297f1fdd24c3bc509ee5fd1bb5969976dc8a160 Mon Sep 17 00:00:00 2001 From: jhilden Date: Wed, 10 Jun 2009 02:07:47 -0400 Subject: first stab at makeing the language admin view prettier --- themes/admin_default/css/screen.css | 4 ++++ 1 file changed, 4 insertions(+) (limited to 'themes') diff --git a/themes/admin_default/css/screen.css b/themes/admin_default/css/screen.css index 82f85f21..de4d2413 100644 --- a/themes/admin_default/css/screen.css +++ b/themes/admin_default/css/screen.css @@ -432,3 +432,7 @@ li.gDefaultGroup h4, li.gDefaultGroup .gUser { cursor: pointer; } +#gLanguageSettingsForm .checklist li { + width: 150px; + overflow: hidden; +} -- cgit v1.2.3