Skip to content
This repository has been archived by the owner on Jun 27, 2019. It is now read-only.

Commit

Permalink
Allow to write a sample without syncing with a repo
Browse files Browse the repository at this point in the history
In some cases it is just wanted to make some tests, starting from scratch.
This patch improves navigability message and changes Library to Projects.

Signed-off-by: Bruno Bottazzini <[email protected]>
  • Loading branch information
Bruno Bottazzini committed Sep 16, 2015
1 parent 2168803 commit 12b791c
Show file tree
Hide file tree
Showing 2 changed files with 12 additions and 7 deletions.
8 changes: 5 additions & 3 deletions client/js/controllers/editor.js
Original file line number Diff line number Diff line change
Expand Up @@ -66,7 +66,7 @@
}, refreshPeriod);
}
});
$scope.libChecked = true;
$scope.libChecked = false;
$scope.codeChecked = true;
$scope.svgChecked = true;
$scope.logged = false;
Expand All @@ -81,11 +81,12 @@
editor.commands.removeCommand("showSettingsMenu");
editor.$blockScrolling = Infinity;
editor.session.setOption("useWorker", false);
editor.setReadOnly(true);
editor.setFontSize(15);
editor.setTheme('ace/theme/monokai');

$scope.fileViewer = 'Please select a file to view its contents';
$scope.fbpType = true;
aceConfig.set("modePath", "js/ace/");
$scope.fileViewer = '# Write FBP Code here.';
$scope.buttonSyncDisabled = false;
$scope.nodeSelected = function(e, data) {
var _l = data.node.li_attr;
Expand Down Expand Up @@ -713,6 +714,7 @@
"repo_url": repo,
}}).success(function(data) {
$scope.refreshTree();
$scope.libChecked = true;
$scope.stopSpin();
}).error(function(data){
alert(data);
Expand Down
11 changes: 7 additions & 4 deletions server/views/index.html
Original file line number Diff line number Diff line change
Expand Up @@ -129,7 +129,7 @@
<input type="text" ng-model="repoUrl" placeholder="Git repository URL" style="outline: 0; width: 320px; margin-right: -2px;" class="inputControls" />
<button type="submit" style="outline: 0; margin-left: -11px;" title="Sync repository git" tabindex="0" id="syncGit" ng-click="syncGit()" ng-disabled="buttonSyncDisabled"/><img src="imgs/button_sync.png"></button>
<!--<button type="button" title="Commit" style="outline: 0; margin-left: -11px;" id="commitGit" ng-click="commitDiag()" ng-disabled="buttonSyncDisabled" href="#"><img src="imgs/button_commit.png"></button>-->
<button type="button" ng-class="{'button_lib_on': libChecked == true, 'button_lib_off': libChecked == false}" ng-click="libChecked = !libChecked" title="Collapse library panel"></button>
<button type="button" ng-class="{'button_lib_on': libChecked == true, 'button_lib_off': libChecked == false}" ng-click="libChecked = !libChecked" title="Collapse projects panel"></button>
<button type="button" ng-class="{'button_code_on': codeChecked == true, 'button_code_off': codeChecked == false}" ng-click="codeChecked = !codeChecked" title="Collapse code panel" ></button>
<button type="button" style="margin-right: 5px;" ng-class="{'button_svg_on': svgChecked == true, 'button_svg_off': svgChecked == false}" ng-click="svgChecked = !svgChecked" title="Collapse SVG panel"></button>
<button type="button" ng-class="processLoginClass()" title="Login" ng-click="logged = !logged"></button>
Expand All @@ -138,12 +138,15 @@
</div>

<div style="vertical-align: text-bottom;">
<div class="blueLabel" style="margin-left:20px; width:330px;">
Library
<div ng-if="libChecked == true" class="blueLabel" style="margin-left:20px; width:330px;">
Projects
</div>
<div class="blueLabel" >
<div class="blueLabel" ng-if="codeChecked == true" >
Code viewer <span>{{fileName}}</span>
</div>
<div class="blueLabel" ng-if="codeChecked == false" >
SVG viewer <span>{{fileName}}</span>
</div>
</div>
<div align="right" class="serviceStatus" style="margin-top: -48px; margin-right: -16px;">
<table ng-class="{'enable_div': runJournal == true, 'disable_div': runJournal == false}" class="running_table">
Expand Down

0 comments on commit 12b791c

Please sign in to comment.