From: James Moger Date: Wed, 5 Oct 2011 12:04:47 +0000 (-0400) Subject: Refactored topbar navigation links to indicate current page. X-Git-Tag: v0.7.0~92^2 X-Git-Url: https://source.dussan.org/?a=commitdiff_plain;h=9e5beeecd2a462337ca5a893bf1458c25df26060;p=gitblit.git Refactored topbar navigation links to indicate current page. --- diff --git a/resources/arrow_page.png b/resources/arrow_page.png new file mode 100644 index 00000000..6d930242 Binary files /dev/null and b/resources/arrow_page.png differ diff --git a/resources/bootstrap.gb.css b/resources/bootstrap.gb.css index cf82c87a..6ff047b1 100644 --- a/resources/bootstrap.gb.css +++ b/resources/bootstrap.gb.css @@ -46,6 +46,12 @@ hr { border-bottom: 2px solid #ff9900 !important; } +.topbar ul li:focus, .topbar .active { + background-repeat:no-repeat; + background-image: url(arrow_page.png); + background-position: center bottom; +} + .breadcrumb { margin-top: 5px !important; margin-bottom: 5px !important; diff --git a/src/com/gitblit/wicket/PageRegistration.java b/src/com/gitblit/wicket/PageRegistration.java new file mode 100644 index 00000000..ac00fb5e --- /dev/null +++ b/src/com/gitblit/wicket/PageRegistration.java @@ -0,0 +1,47 @@ +/* + * Copyright 2011 gitblit.com. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +package com.gitblit.wicket; + +import java.io.Serializable; + +import org.apache.wicket.PageParameters; + +import com.gitblit.wicket.pages.BasePage; + +/** + * Represents a page link registration for the topbar. + * + * @author James Moger + * + */ +public class PageRegistration implements Serializable { + private static final long serialVersionUID = 1L; + + public final String translationKey; + public final Class pageClass; + public final PageParameters params; + + public PageRegistration(String translationKey, Class pageClass) { + this(translationKey, pageClass, null); + } + + public PageRegistration(String translationKey, Class pageClass, + PageParameters params) { + this.translationKey = translationKey; + this.pageClass = pageClass; + this.params = params; + } +} \ No newline at end of file diff --git a/src/com/gitblit/wicket/pages/RepositoryPage.html b/src/com/gitblit/wicket/pages/RepositoryPage.html index 100016f1..c60275ab 100644 --- a/src/com/gitblit/wicket/pages/RepositoryPage.html +++ b/src/com/gitblit/wicket/pages/RepositoryPage.html @@ -15,18 +15,13 @@ - + + + + + + +