Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Ui configs #82

Open
wants to merge 84 commits into
base: master
Choose a base branch
from
Open
Changes from 1 commit
Commits
Show all changes
84 commits
Select commit Hold shift + click to select a range
9bbb9a6
Prepare for diagram constructing
artbez Nov 2, 2016
13eb1ef
Create Scene and Pallete services
artbez Nov 3, 2016
f88ade9
Add exist method to Scene
artbez Nov 3, 2016
218c5ff
Add remove and move methods
artbez Nov 3, 2016
3a55d67
Add logging
artbez Nov 4, 2016
d4e6d8b
Add addLink method
artbez Nov 4, 2016
00ccd70
Codacy
artbez Nov 4, 2016
69b61d0
Add PropertyEditor service
artbez Nov 4, 2016
ec6feba
Add possibility to move element to any point in the scene
artbez Nov 14, 2016
a026b52
Code refactor of SceneWindow
artbez Nov 15, 2016
8bc01b9
Merge branch 'master' into diagram-gui
artbez Nov 15, 2016
3fb78a3
Create testspace for tasting
artbez Nov 22, 2016
d44c095
Fix movement bug
artbez Nov 23, 2016
a55e457
Change namespace of nodes
artbez Nov 23, 2016
60a30c6
Fix bug with property checkbox
artbez Nov 24, 2016
aaaeb59
Add HeaderPanel
artbez Nov 30, 2016
bf95628
Some experiments with JSExecutor
artbez Dec 18, 2016
8e6c356
Add Block and Coordinate classes
artbez Jan 15, 2017
970860c
Add Link and change SelenideElement to links and blocks in scene service
artbez Jan 18, 2017
1ddddf8
Code refactor
artbez Feb 12, 2017
af4b4be
Fix focus
artbez Feb 14, 2017
0b62cb2
Fix clean scene
artbez Feb 18, 2017
70e67bf
Make SceneWindow steps calculated automatically
artbez Feb 18, 2017
64e8b53
Code refactor
artbez Feb 19, 2017
6124f7a
Code refactor
artbez Feb 19, 2017
7403a31
Add class PalleteElement + code refactor
artbez Feb 19, 2017
dc0b9c2
Code refactor
artbez Feb 19, 2017
56672d0
Code refactor
artbez Feb 19, 2017
de3d452
Merge remote-tracking branch 'remotes/origin/master' into diagram-gui
artbez Feb 19, 2017
ffdfc41
Add callTomcat.sh
artbez Feb 19, 2017
b17459c
Code refactor
artbez Feb 19, 2017
65f2482
Divide editor to editor/robots and editor/bpmn
artbez Feb 23, 2017
4723a4c
Add Page as an object
artbez Feb 24, 2017
16ef59c
Remove Scene, PropertyEditor and Pallete from beans
artbez Feb 24, 2017
49765e7
Code refactor
artbez Feb 24, 2017
447413f
Add Block and Link providers
artbez Feb 24, 2017
2441162
Add additional condition for remove
artbez Feb 26, 2017
e77cadb
Make focus works by JavaScriptExecutor
artbez Feb 26, 2017
a001a6d
Add webdriver's timeouts
artbez Feb 26, 2017
e0f2193
Fix bug with movement
artbez Mar 2, 2017
d2235ef
Remove unnecessary changes
artbez Mar 3, 2017
e94789c
Merge branch 'diagram-gui' into save-open-dia-test
artbez Mar 9, 2017
3a5ea63
Add titles in pages
artbez Mar 9, 2017
ce0fee8
Remove unnecessary modal call
artbez Mar 12, 2017
3f41d7b
Add save diagram test
artbez Mar 13, 2017
7108d8d
Add equals check for diagrams
artbez Mar 14, 2017
1d89f57
Fix bug with deleting folders and some code refactor
artbez Mar 19, 2017
b2250ac
Code refactor, java doc and style guide
artbez Mar 19, 2017
6e4cb49
Merge branch 'diagram-gui' into save-open-dia-test
artbez Mar 19, 2017
fc2fa52
Code refactor, java doc and style guide
artbez Mar 19, 2017
a5badfb
Merge branch 'master' into save-open-dia-test
artbez Mar 21, 2017
dd04798
Merge branch 'master' into save-open-dia-test
artbez Mar 21, 2017
783c623
Fix bug with gesture creating
artbez Mar 21, 2017
329cbea
Merge branch 'master' into diagram-gui
artbez Mar 21, 2017
bb65fb9
Merge branch 'master' into diagram-gui
artbez Mar 21, 2017
989fb6f
Code refactor
artbez Mar 21, 2017
e380a67
Add drawing line between blocks
artbez Apr 1, 2017
cb15fbe
Add gestures support
artbez Apr 1, 2017
ef435cc
Fix bug with not catching mousemove event
artbez Apr 2, 2017
a81dde9
Code refactor
artbez Apr 2, 2017
7626b1c
Add first version of config files
artbez Apr 11, 2017
30d395d
Add configMerger and integrate opener service with selector service
artbez Apr 11, 2017
cc940c5
Add selector service
artbez Apr 27, 2017
2995bc2
Code refactor
artbez Apr 27, 2017
8176207
Merge branch 'diagram-gui' into save-open-dia-test
artbez Apr 27, 2017
184eaac
Code refactor
artbez Apr 27, 2017
a824ba4
Merge branch 'save-open-dia-test' into mouse-gestures
artbez Apr 27, 2017
db85348
Code refactor
artbez Apr 27, 2017
a5a7c3c
Merge branch 'mouse-gestures' into ui-configs
artbez Apr 27, 2017
eece7a3
Code refactor
artbez Apr 27, 2017
66f2599
Fix bug with timing
artbez Apr 27, 2017
777a26e
Merge branch 'mouse-gestures' into ui-configs
artbez Apr 27, 2017
0bc2008
Add angular service to client
artbez Apr 29, 2017
2f456d3
Add Selector Service
artbez May 1, 2017
98ab11e
Let typescript files get selectors from server
artbez May 2, 2017
c0a18bc
Integrate selectors for PropertyEditor
artbez May 2, 2017
8a953dd
Create selectors for property in PropertyEditor
artbez May 2, 2017
674e119
Integrate EditorPanelHeader.fileItem and EditorPanelHeader.saveDiagra…
artbez May 3, 2017
7c1e3f9
Integrate EditorPanelHeader.savingMenu
artbez May 3, 2017
fcb6db1
Integrate EditorPanelHeader
artbez May 4, 2017
9de0f91
Integrate all configs
artbez May 4, 2017
e8a5631
Change SelectorService interface
artbez May 4, 2017
5d671a2
Add property files
artbez May 4, 2017
1549924
Code refactor
artbez May 5, 2017
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Prev Previous commit
Next Next commit
Make SceneWindow steps calculated automatically
artbez committed Feb 18, 2017
commit 70e67bfb892a1916f2afd34f8608faf1748ee631
Original file line number Diff line number Diff line change
@@ -33,11 +33,9 @@ public class SceneWindow {
public SceneWindow(final Scene scene, final WebDriver driver) {
this.scene = scene;
this.driver = driver;
stepHor = 40;
stepVert = 40;
updateCanvasInfo(driver);
updateSteps();
}

/**
* Moves element to the requested position.
*
@@ -87,14 +85,14 @@ private void horizontalWindowMovement(int horizontal) {

if (left + sizeHor * 2 / 3 < horizontal) {
sendKey(Keys.RIGHT);
updateCanvasInfo(driver);
updateCanvasInfo();
if (Double.valueOf($(By.id("SceneWindowLeft")).innerHtml()).intValue() != left) {
horizontalWindowMovement(horizontal);
}
}
if (left + sizeHor / 3 > horizontal) {
sendKey(Keys.LEFT);
updateCanvasInfo(driver);
updateCanvasInfo();
if (Double.valueOf($(By.id("SceneWindowLeft")).innerHtml()).intValue() != left) {
horizontalWindowMovement(horizontal);
}
@@ -108,14 +106,14 @@ private void verticalWindowMovement(int vertical) {

if (top + sizeVer * 2 / 3 < vertical) {
sendKey(Keys.DOWN);
updateCanvasInfo(driver);
updateCanvasInfo();
if (Double.valueOf($(By.id("SceneWindowTop")).innerHtml()).intValue() != top) {
verticalWindowMovement(vertical);
}
}
if (top + sizeVer / 3 > vertical) {
sendKey(Keys.UP);
updateCanvasInfo(driver);
updateCanvasInfo();
if (Double.valueOf($(By.id("SceneWindowTop")).innerHtml()).intValue() != top) {
verticalWindowMovement(vertical);
}
@@ -163,7 +161,7 @@ private Coordinate finalJump(Block block, Coordinate dist) throws ElementNotOnTh
return block.getCoordinateOnScene();
}

private void updateCanvasInfo(WebDriver driver) {
private void updateCanvasInfo() {
if (driver instanceof JavascriptExecutor) {
((JavascriptExecutor) driver).executeScript("var canvas = " +
"document.getElementsByClassName(\"scene-wrapper\")[0]; " +
@@ -184,4 +182,16 @@ private void sendKey(Keys key) {
e.printStackTrace();
}
}

private void updateSteps() {
updateCanvasInfo();
$(Scene.selector).click();
focus(new Coordinate(0, 0));
updateCanvasInfo();
sendKey(Keys.DOWN);
sendKey(Keys.RIGHT);
updateCanvasInfo();
stepHor = Double.valueOf($(By.id("SceneWindowLeft")).innerHtml()).intValue();
stepVert = Double.valueOf($(By.id("SceneWindowTop")).innerHtml()).intValue();
}
}