Skip to content

Commit

Permalink
add version to project file
Browse files Browse the repository at this point in the history
  • Loading branch information
A1Gard committed May 30, 2021
1 parent a3d7351 commit fe09c10
Show file tree
Hide file tree
Showing 6 changed files with 29 additions and 27 deletions.
2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "anubias",
"version": "0.4.0",
"version": "0.4.1",
"private": false,
"description": "anubias desktop application",
"author": {
Expand Down
15 changes: 14 additions & 1 deletion src/assets/js/winVars.js
Original file line number Diff line number Diff line change
@@ -1,3 +1,15 @@
/**
* ide version :)
* @type {{}}
*/
window.ide = {
majorVersion: 0,
minorVersion: 4,
patchVersion: 1,
version:function () {
return this.majorVersion + '.' + this.minorVersion + '.' + this.patchVersion;
}
};
/**
* sample application date
*/
Expand All @@ -12,7 +24,8 @@ window.sample = {
bgColor: '#ffffff',
mainPage: 0
},
pages: []
pages: [],
version: window.ide.version()
};
/**
* main application data
Expand Down
6 changes: 4 additions & 2 deletions src/components/elements/AppMenuElement.vue
Original file line number Diff line number Diff line change
Expand Up @@ -83,6 +83,7 @@ export default {
return false;
}
// otherwise try to save
window.appData.version = window.ide.version();
var data = {
project: window.project,
data: window.appData
Expand All @@ -96,8 +97,8 @@ export default {

// prepare new empty project
window.project = {
'folder': '',
'file': '',
folder: '',
file: '',
isSave: false,
};
window.appData = fnc.clone(window.sample);
Expand All @@ -111,6 +112,7 @@ export default {
return false;
}

window.appData.version = window.ide.version();
// prepare save dialog and appDate to save as
var data = {
dialog: {
Expand Down
22 changes: 2 additions & 20 deletions src/components/elements/CodeEditor.vue
Original file line number Diff line number Diff line change
Expand Up @@ -17,23 +17,6 @@ export default {
require("@/assets/js/xscript");
require("@/assets/js/xScriptSnipts");
require('brace/theme/dracula');
// let snippetManager = ace.acequire('ace/snippets').snippetManager;
// editor.setValue([
// '// JavaScript'
// , 'var a = 3;'
// , ''
// , '// below line has an error which is annotated'
// , 'var b ='
// ].join('\n')
// );
// editor.clearSelection();
// console.log('hello');
// console.log(snippetManager);
// console.log('bye');
// let customSnippet = snippetManager.parseSnippetFile(xscript, 'xscript');
//
let editor = ace.edit('codeEditor');
editor.getSession().setMode('ace/mode/xscript');
Expand All @@ -45,12 +28,11 @@ export default {
highlightActiveLine: false,
enableSnippets: true,
showLineNumbers: true,
tabSize: 2,
tabSize: 4,
showPrintMargin: false,
showGutter: true,
});
// snippetManager.register(editor, editor.session, customSnippet, 'xscript');
// console.log(xscript);
}
}
</script>
Expand Down
9 changes: 7 additions & 2 deletions src/components/pages/AboutPage.vue
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@
</titlec>
<div>
<h1>
Abubias v0.2.1
Abubias v{{version}}
</h1>
<img src="@/assets/img/logo.svg" alt="logo" class="logo">
<h2>
Expand Down Expand Up @@ -773,6 +773,11 @@ import titlec from '../elements/TitleElement';
export default {
name: "AboutPage",
data:function () {
return{
version: window.ide.version()
};
},
components: {
titlec
}, mounted() {
Expand All @@ -783,7 +788,7 @@ export default {
draggable: true,
wrapAround: true,
autoPlay: 3500,
pauseAutoPlayOnHover: true,
pauseAutoPlayOnHover: true
});
var onScroll = function() {
var scrollTop = $(this).scrollTop();
Expand Down
2 changes: 1 addition & 1 deletion src/components/pages/MainAppPage.vue
Original file line number Diff line number Diff line change
Expand Up @@ -159,7 +159,7 @@
</div>

</div>
<modal :active="true" ref="modal">
<modal :active="false" ref="modal">
<code-editor></code-editor>
</modal>
</div>
Expand Down

0 comments on commit fe09c10

Please sign in to comment.