mirror of
https://github.com/antos-rde/antosdk-apps.git
synced 2024-11-19 11:48:22 +01:00
Antedit: support horizontal scrolling on horizontal tabbar
This commit is contained in:
parent
b8734fdc50
commit
eb7162b901
@ -6,6 +6,7 @@ The editor functionality can be extended by its extension mechanism.
|
|||||||
Extension can be developed/released/isntalled by the editor itself.
|
Extension can be developed/released/isntalled by the editor itself.
|
||||||
|
|
||||||
### Change logs
|
### Change logs
|
||||||
|
- 0.2.2-b: Support horizotal scrolling on horizotal tabbars
|
||||||
- 0.2.1-b: Add open file to right, editor actions are only attached to code editor
|
- 0.2.1-b: Add open file to right, editor actions are only attached to code editor
|
||||||
- 0.2.0-b: Support diff mode in editor + fix new Monaco version compatible bug
|
- 0.2.0-b: Support diff mode in editor + fix new Monaco version compatible bug
|
||||||
- 0.1.17-b: Fix extension keybinding bug with the new monaco editor
|
- 0.1.17-b: Fix extension keybinding bug with the new monaco editor
|
||||||
|
@ -23,7 +23,7 @@
|
|||||||
</afx-tab-container>
|
</afx-tab-container>
|
||||||
</afx-vbox>
|
</afx-vbox>
|
||||||
<afx-resizer data-width = "3" ></afx-resizer>
|
<afx-resizer data-width = "3" ></afx-resizer>
|
||||||
<afx-vbox>
|
<afx-vbox data-id="editor-main-container">
|
||||||
<afx-hbox>
|
<afx-hbox>
|
||||||
<afx-vbox data-id="left-panel">
|
<afx-vbox data-id="left-panel">
|
||||||
<afx-tab-bar closable="true" data-height="26" data-id = "left-tabbar"></afx-tab-bar>
|
<afx-tab-bar closable="true" data-height="26" data-id = "left-tabbar"></afx-tab-bar>
|
||||||
|
@ -6,6 +6,7 @@ The editor functionality can be extended by its extension mechanism.
|
|||||||
Extension can be developed/released/isntalled by the editor itself.
|
Extension can be developed/released/isntalled by the editor itself.
|
||||||
|
|
||||||
### Change logs
|
### Change logs
|
||||||
|
- 0.2.2-b: Support horizotal scrolling on horizotal tabbars
|
||||||
- 0.2.1-b: Add open file to right, editor actions are only attached to code editor
|
- 0.2.1-b: Add open file to right, editor actions are only attached to code editor
|
||||||
- 0.2.0-b: Support diff mode in editor + fix new Monaco version compatible bug
|
- 0.2.0-b: Support diff mode in editor + fix new Monaco version compatible bug
|
||||||
- 0.1.17-b: Fix extension keybinding bug with the new monaco editor
|
- 0.1.17-b: Fix extension keybinding bug with the new monaco editor
|
||||||
|
File diff suppressed because one or more lines are too long
@ -7,7 +7,7 @@
|
|||||||
"author": "Xuan Sang LE",
|
"author": "Xuan Sang LE",
|
||||||
"email": "mrsang@iohub.dev"
|
"email": "mrsang@iohub.dev"
|
||||||
},
|
},
|
||||||
"version": "0.2.1-b",
|
"version": "0.2.2-b",
|
||||||
"category": "Development",
|
"category": "Development",
|
||||||
"iconclass": "bi bi-journal-code",
|
"iconclass": "bi bi-journal-code",
|
||||||
"mimes": [
|
"mimes": [
|
||||||
|
@ -23,7 +23,7 @@
|
|||||||
</afx-tab-container>
|
</afx-tab-container>
|
||||||
</afx-vbox>
|
</afx-vbox>
|
||||||
<afx-resizer data-width = "3" ></afx-resizer>
|
<afx-resizer data-width = "3" ></afx-resizer>
|
||||||
<afx-vbox>
|
<afx-vbox data-id="editor-main-container">
|
||||||
<afx-hbox>
|
<afx-hbox>
|
||||||
<afx-vbox data-id="left-panel">
|
<afx-vbox data-id="left-panel">
|
||||||
<afx-tab-bar closable="true" data-height="26" data-id = "left-tabbar"></afx-tab-bar>
|
<afx-tab-bar closable="true" data-height="26" data-id = "left-tabbar"></afx-tab-bar>
|
||||||
|
Binary file not shown.
@ -7,7 +7,7 @@
|
|||||||
"author": "Xuan Sang LE",
|
"author": "Xuan Sang LE",
|
||||||
"email": "mrsang@iohub.dev"
|
"email": "mrsang@iohub.dev"
|
||||||
},
|
},
|
||||||
"version": "0.2.1-b",
|
"version": "0.2.2-b",
|
||||||
"category": "Development",
|
"category": "Development",
|
||||||
"iconclass": "bi bi-journal-code",
|
"iconclass": "bi bi-journal-code",
|
||||||
"mimes": [
|
"mimes": [
|
||||||
|
@ -191,7 +191,6 @@ namespace OS {
|
|||||||
return false;
|
return false;
|
||||||
}*/
|
}*/
|
||||||
if (!this.currfile.dirty) {
|
if (!this.currfile.dirty) {
|
||||||
console.log("dirty", this.currfile.path);
|
|
||||||
this.currfile.dirty = true;
|
this.currfile.dirty = true;
|
||||||
this.currfile.text += "*";
|
this.currfile.text += "*";
|
||||||
return this.tabbar.update(undefined);
|
return this.tabbar.update(undefined);
|
||||||
@ -268,7 +267,8 @@ namespace OS {
|
|||||||
this.currfile.selected = false;
|
this.currfile.selected = false;
|
||||||
file.selected = true;
|
file.selected = true;
|
||||||
//console.log cnt
|
//console.log cnt
|
||||||
this.tabbar.push(file);
|
const el = this.tabbar.push(file);
|
||||||
|
this.app.trigger("tab-opened", el);
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
|
@ -472,6 +472,17 @@ namespace OS {
|
|||||||
this.bindKey("CTRL-S", () => this.menuAction("save"));
|
this.bindKey("CTRL-S", () => this.menuAction("save"));
|
||||||
this.bindKey("ALT-W", () => this.menuAction("saveas"));
|
this.bindKey("ALT-W", () => this.menuAction("saveas"));
|
||||||
|
|
||||||
|
const list_container = $(".list-container", this.find("editor-main-container"));
|
||||||
|
list_container.each((i,el) => {
|
||||||
|
$(el).on("wheel", (evt)=>{
|
||||||
|
el.scrollLeft += (evt.originalEvent as WheelEvent).deltaY;
|
||||||
|
});
|
||||||
|
});
|
||||||
|
this.on("tab-opened", (el) => {
|
||||||
|
const container = $(el).closest(".list-container");
|
||||||
|
if(container && container[0])
|
||||||
|
container[0].scrollLeft = container[0].scrollWidth;
|
||||||
|
});
|
||||||
this.fileview.ondragndrop = (e) => {
|
this.fileview.ondragndrop = (e) => {
|
||||||
if(!e.data.from || !e.data.to)
|
if(!e.data.from || !e.data.to)
|
||||||
{
|
{
|
||||||
|
@ -45,7 +45,7 @@
|
|||||||
"description": "https://raw.githubusercontent.com/lxsang/antosdk-apps/master/Antedit/README.md",
|
"description": "https://raw.githubusercontent.com/lxsang/antosdk-apps/master/Antedit/README.md",
|
||||||
"category": "Development",
|
"category": "Development",
|
||||||
"author": "Xuan Sang LE",
|
"author": "Xuan Sang LE",
|
||||||
"version": "0.2.1-b",
|
"version": "0.2.2-b",
|
||||||
"dependencies": ["MonacoCore@0.33.0-r"],
|
"dependencies": ["MonacoCore@0.33.0-r"],
|
||||||
"download": "https://raw.githubusercontent.com/lxsang/antosdk-apps/master/Antedit/build/release/Antedit.zip"
|
"download": "https://raw.githubusercontent.com/lxsang/antosdk-apps/master/Antedit/build/release/Antedit.zip"
|
||||||
},
|
},
|
||||||
|
Loading…
Reference in New Issue
Block a user