The Unified and Autonomous Development Platform
Make scrollbar speedup works much accurate.
robin shine40ed4ecd5f88
diff --git a/commons.wicket/src/main/java/com/pmease/commons/wicket/assets/codemirror/simplescrollbars.js b/commons.wicket/src/main/java/com/pmease/commons/wicket/assets/codemirror/simplescrollbars.jsindex e17fe6bee4..adad8b48ae 100644--- a/commons.wicket/src/main/java/com/pmease/commons/wicket/assets/codemirror/simplescrollbars.js+++ b/commons.wicket/src/main/java/com/pmease/commons/wicket/assets/codemirror/simplescrollbars.js@@ -55,7 +55,6 @@if (self.inner == e.target)return;- console.log("down");CodeMirror.e_preventDefault(e);var innerBox = self.inner.getBoundingClientRect(), where;if (self.orientation == "horizontal")@@ -67,18 +66,12 @@self.originWhere = where;if (self.originWhere<0 && where<0 || self.originWhere>0 && where>0) {- self.moveTo(self.pos + where * self.screen * self.downRepeat);-- var timeout;- if (self.downRepeat == 1)- timeout = 500;- else- timeout = 100;-+ self.moveTo(self.pos + where * self.screen);+self.downRepeatTimer = setTimeout(function() {self.downRepeat++;onBarMouseDown(e);- }, timeout);+ }, 500/self.downRepeat/self.downRepeat);}}diff --git a/gitplex.web/src/main/java/com/pmease/gitplex/web/page/TestPage.java b/gitplex.web/src/main/java/com/pmease/gitplex/web/page/TestPage.javaindex aa75244168..a7dfbcae9b 100644--- a/gitplex.web/src/main/java/com/pmease/gitplex/web/page/TestPage.java+++ b/gitplex.web/src/main/java/com/pmease/gitplex/web/page/TestPage.java@@ -117,7 +117,7 @@ public class TestPage extends BasePage {try {RevTree revTree = new RevWalk(jgitRepo).parseCommit(repository.resolveRevision("master")).getTree();TreeWalk treeWalk = TreeWalk.forPath(jgitRepo,- "gitplex.web/src/main/java/com/pmease/gitplex/web/component/search/BlobSearchPanel.java",+ "gitplex.core/src/main/java/com/pmease/gitplex/core/manager/impl/DefaultPullRequestManager.java",revTree);ObjectLoader objectLoader = jgitRepo.open(treeWalk.getObjectId(0));String content = new String(objectLoader.getCachedBytes());@@ -129,8 +129,8 @@ public class TestPage extends BasePage {}*/try {- String content = FileUtils.readFileToString(new File("w:\\temp\\Component.java"));- return new Source("master", "Component.java", content);+ String content = FileUtils.readFileToString(new File("W:\\temp\\com\\sun\\org\\apache\\regexp\\internal\\RE.java"));+ return new Source("master", "RE.java", content);} catch (IOException e) {throw new RuntimeException(e);}