summaryrefslogtreecommitdiffstats
path: root/src/main/java
diff options
context:
space:
mode:
authorJames Moger <james.moger@gitblit.com>2013-06-19 16:24:55 -0400
committerJames Moger <james.moger@gitblit.com>2013-06-19 16:24:55 -0400
commitbdfb4cbb8175c09beaf77c7270d36403b127a0de (patch)
treec451a9a518752d732382aab29bc92618cb10da05 /src/main/java
parentdaaf89d8bc0b8229c6205d0c59326bee183c5c5e (diff)
downloadgitblit-bdfb4cbb8175c09beaf77c7270d36403b127a0de.tar.gz
gitblit-bdfb4cbb8175c09beaf77c7270d36403b127a0de.zip
Fixed tablet/phone scaling on dashboards. Improved digests title.
Diffstat (limited to 'src/main/java')
-rw-r--r--src/main/java/com/gitblit/wicket/GitBlitWebApp.properties3
-rw-r--r--src/main/java/com/gitblit/wicket/pages/DashboardPage.java5
-rw-r--r--src/main/java/com/gitblit/wicket/pages/MyDashboardPage.html4
-rw-r--r--src/main/java/com/gitblit/wicket/pages/MyDashboardPage.java2
-rw-r--r--src/main/java/com/gitblit/wicket/pages/ProjectPage.html6
-rw-r--r--src/main/java/com/gitblit/wicket/pages/ProjectPage.java2
6 files changed, 11 insertions, 11 deletions
diff --git a/src/main/java/com/gitblit/wicket/GitBlitWebApp.properties b/src/main/java/com/gitblit/wicket/GitBlitWebApp.properties
index f7e72ca9..f3c6d71d 100644
--- a/src/main/java/com/gitblit/wicket/GitBlitWebApp.properties
+++ b/src/main/java/com/gitblit/wicket/GitBlitWebApp.properties
@@ -495,4 +495,5 @@ gb.failedToFindAccount = failed to find user account ''{0}''
gb.reflog = reflog
gb.active = active
gb.starred = starred
-gb.owned = owned \ No newline at end of file
+gb.owned = owned
+gb.starredAndOwned = starred & owned \ No newline at end of file
diff --git a/src/main/java/com/gitblit/wicket/pages/DashboardPage.java b/src/main/java/com/gitblit/wicket/pages/DashboardPage.java
index 1c45b64a..3c2828b7 100644
--- a/src/main/java/com/gitblit/wicket/pages/DashboardPage.java
+++ b/src/main/java/com/gitblit/wicket/pages/DashboardPage.java
@@ -52,7 +52,6 @@ import com.gitblit.wicket.GitBlitWebApp;
import com.gitblit.wicket.PageRegistration;
import com.gitblit.wicket.PageRegistration.DropDownMenuItem;
import com.gitblit.wicket.PageRegistration.DropDownMenuRegistration;
-import com.gitblit.wicket.WicketUtils;
import com.gitblit.wicket.charting.GoogleChart;
import com.gitblit.wicket.charting.GoogleCharts;
import com.gitblit.wicket.charting.GooglePieChart;
@@ -75,7 +74,7 @@ public abstract class DashboardPage extends RootPage {
return true;
}
- protected void addActivity(UserModel user, Collection<RepositoryModel> repositories, int daysBack) {
+ protected void addActivity(UserModel user, Collection<RepositoryModel> repositories, boolean isStarred, int daysBack) {
Calendar c = Calendar.getInstance();
c.add(Calendar.DATE, -1*daysBack);
Date minimumDate = c.getTime();
@@ -92,6 +91,7 @@ public abstract class DashboardPage extends RootPage {
Fragment activityFragment = new Fragment("activity", "activityFragment", this);
add(activityFragment);
+ activityFragment.add(new Label("feedTitle", getString( isStarred ? "gb.starredAndOwned" : "gb.recentActivity")));
if (digests.size() == 0) {
// quiet or no starred repositories
if (repositories.size() == 0) {
@@ -107,7 +107,6 @@ public abstract class DashboardPage extends RootPage {
// show daily commit digest feed
Collections.sort(digests);
DigestsPanel digestsPanel = new DigestsPanel("digests", digests);
- WicketUtils.setCssStyle(digestsPanel, "margin-top:-20px");
activityFragment.add(digestsPanel);
}
diff --git a/src/main/java/com/gitblit/wicket/pages/MyDashboardPage.html b/src/main/java/com/gitblit/wicket/pages/MyDashboardPage.html
index 6b78b140..a9fd1bae 100644
--- a/src/main/java/com/gitblit/wicket/pages/MyDashboardPage.html
+++ b/src/main/java/com/gitblit/wicket/pages/MyDashboardPage.html
@@ -10,7 +10,7 @@
<div class="row" style="padding-top:5px;">
<div class="span7">
- <div class="hidden-phone markdown" style="padding-bottom: 30px;" wicket:id="repositoriesMessage">[repositories message]</div>
+ <div class="hidden-phone hidden-tablet markdown" style="padding-bottom: 30px;" wicket:id="repositoriesMessage">[repositories message]</div>
<div wicket:id="activity"></div>
</div>
<div class="span5">
@@ -58,7 +58,7 @@
</wicket:fragment>
<wicket:fragment wicket:id="activityFragment">
- <div class="dashboardTitle"><wicket:message key="gb.recentActivity"></wicket:message> <small><span wicket:id="feedheader"></span></small></div>
+ <div class="dashboardTitle"><span class="hidden-phone hidden-tablet" wicket:id="feedTitle"></span> <small><span wicket:id="feedheader"></span></small></div>
<div class="hidden-phone hidden-tablet" style="text-align:center;">
<div wicket:id="charts"></div>
</div>
diff --git a/src/main/java/com/gitblit/wicket/pages/MyDashboardPage.java b/src/main/java/com/gitblit/wicket/pages/MyDashboardPage.java
index b0c89b72..858821d4 100644
--- a/src/main/java/com/gitblit/wicket/pages/MyDashboardPage.java
+++ b/src/main/java/com/gitblit/wicket/pages/MyDashboardPage.java
@@ -141,7 +141,7 @@ public class MyDashboardPage extends DashboardPage {
feed.addAll(active);
}
- addActivity(user, feed, daysBack);
+ addActivity(user, feed, starred.size() > 0 || owned.size() > 0, daysBack);
Fragment repositoryTabs;
if (UserModel.ANONYMOUS.equals(user)) {
diff --git a/src/main/java/com/gitblit/wicket/pages/ProjectPage.html b/src/main/java/com/gitblit/wicket/pages/ProjectPage.html
index 9fbe1b2d..102a49e6 100644
--- a/src/main/java/com/gitblit/wicket/pages/ProjectPage.html
+++ b/src/main/java/com/gitblit/wicket/pages/ProjectPage.html
@@ -25,18 +25,18 @@
<div class="row">
<div class="span7">
- <div class="markdown" style="padding-bottom: 30px;" wicket:id="projectMessage">[project message]</div>
+ <div class="hidden-phone hidden-tablet markdown" style="padding-bottom: 30px;" wicket:id="projectMessage">[project message]</div>
<div wicket:id="activity">[activity panel]</div>
</div>
<div class="span5">
- <div class="markdown" wicket:id="repositoriesMessage">[repositories message]</div>
+ <div class="hidden-phone hidden-tablet markdown" wicket:id="repositoriesMessage">[repositories message]</div>
<div wicket:id="repositoryList">[repository list]</div>
</div>
</div>
</div>
<wicket:fragment wicket:id="activityFragment">
- <div class="dashboardTitle"><wicket:message key="gb.recentActivity"></wicket:message> <small><span wicket:id="feedheader"></span></small></div>
+ <div class="dashboardTitle"><span class="hidden-phone hidden-tablet" wicket:id="feedTitle"></span> <small><span wicket:id="feedheader"></span></small></div>
<div class="hidden-phone hidden-tablet" style="text-align:center;">
<div wicket:id="charts"></div>
</div>
diff --git a/src/main/java/com/gitblit/wicket/pages/ProjectPage.java b/src/main/java/com/gitblit/wicket/pages/ProjectPage.java
index c64e900a..b101b400 100644
--- a/src/main/java/com/gitblit/wicket/pages/ProjectPage.java
+++ b/src/main/java/com/gitblit/wicket/pages/ProjectPage.java
@@ -123,7 +123,7 @@ public class ProjectPage extends DashboardPage {
});
- addActivity(user, repositories, daysBack);
+ addActivity(user, repositories, false, daysBack);
if (repositories.isEmpty()) {
add(new Label("repositoryList").setVisible(false));