Skip to main content
aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
Diffstat (limited to 'org.eclipse.egit.ui/src/org/eclipse/egit/ui/internal/history/GitHistoryPage.java')
-rw-r--r--org.eclipse.egit.ui/src/org/eclipse/egit/ui/internal/history/GitHistoryPage.java11
1 files changed, 7 insertions, 4 deletions
diff --git a/org.eclipse.egit.ui/src/org/eclipse/egit/ui/internal/history/GitHistoryPage.java b/org.eclipse.egit.ui/src/org/eclipse/egit/ui/internal/history/GitHistoryPage.java
index bf79cf5eae..50e596c12d 100644
--- a/org.eclipse.egit.ui/src/org/eclipse/egit/ui/internal/history/GitHistoryPage.java
+++ b/org.eclipse.egit.ui/src/org/eclipse/egit/ui/internal/history/GitHistoryPage.java
@@ -4,6 +4,7 @@
* Copyright (c) 2010, Stefan Lay <stefan.lay@sap.com>
* Copyright (C) 2010, Mathias Kinzler <mathias.kinzler@sap.com>
* Copyright (C) 2010-2011, Matthias Sohn <matthias.sohn@sap.com>
+ * Copyright (C) 2012, Daniel megert <daniel_megert@ch.ibm.com>
*
* All rights reserved. This program and the accompanying materials
* are made available under the terms of the Eclipse Public License v1.0
@@ -597,8 +598,7 @@ public class GitHistoryPage extends HistoryPage implements RefsChangedListener {
public void propertyChange(PropertyChangeEvent event) {
if (UIPreferences.RESOURCEHISTORY_SHOW_RELATIVE_DATE.equals(event
.getProperty()))
- if (graph.setRelativeDate(((Boolean) event.getNewValue())
- .booleanValue()))
+ if (graph.setRelativeDate(isShowingRelativeDates()))
graph.getTableView().refresh();
}
};
@@ -709,8 +709,7 @@ public class GitHistoryPage extends HistoryPage implements RefsChangedListener {
graphDetailSplit);
graph = new CommitGraphTable(graphDetailSplit, getSite(), popupMgr);
- graph.setRelativeDate(Activator.getDefault().getPreferenceStore()
- .getBoolean(UIPreferences.RESOURCEHISTORY_SHOW_RELATIVE_DATE));
+ graph.setRelativeDate(isShowingRelativeDates());
Activator.getDefault().getPreferenceStore()
.addPropertyChangeListener(listener);
@@ -1865,4 +1864,8 @@ public class GitHistoryPage extends HistoryPage implements RefsChangedListener {
job = null;
}
}
+
+ private boolean isShowingRelativeDates() {
+ return Activator.getDefault().getPreferenceStore().getBoolean(UIPreferences.RESOURCEHISTORY_SHOW_RELATIVE_DATE);
+ }
}

Back to the top