From 2af909117daad59e9aa7c76f9624e2070ab90667 Mon Sep 17 00:00:00 2001 From: Xuan Sang LE Date: Fri, 5 Jun 2020 22:07:00 +0200 Subject: [PATCH] About: fix content padding is not correct on some browser --- About/README.md | 4 + About/assets/scheme.html | 12 ++- About/build/debug/README.md | 4 + About/build/debug/main.css | 9 ++ About/build/debug/package.json | 2 +- About/build/debug/scheme.html | 12 ++- About/build/release/About.zip | Bin 2259 -> 2705 bytes About/css/main.css | 9 ++ About/package.json | 2 +- ActivityMonitor/build/debug/main.js | 131 +++++++++++++++++++++++++++- packages.json | 2 +- 11 files changed, 177 insertions(+), 10 deletions(-) diff --git a/About/README.md b/About/README.md index 447e540..86fc78e 100644 --- a/About/README.md +++ b/About/README.md @@ -4,6 +4,10 @@ This is an example project, generated by AntOS Development Kit It is used to show the change logs of the current AntOS version ## Change logs + +### v0.0.5-a +* Fix cotent padding is not correct on some browsers + ### v0.0.4-a * Add color style to link * Fix some minor bugs \ No newline at end of file diff --git a/About/assets/scheme.html b/About/assets/scheme.html index 6521312..625e6bd 100644 --- a/About/assets/scheme.html +++ b/About/assets/scheme.html @@ -1,10 +1,16 @@ -
- +
+ +
+
+
+
+
+
-
+
\ No newline at end of file diff --git a/About/build/debug/README.md b/About/build/debug/README.md index 447e540..86fc78e 100644 --- a/About/build/debug/README.md +++ b/About/build/debug/README.md @@ -4,6 +4,10 @@ This is an example project, generated by AntOS Development Kit It is used to show the change logs of the current AntOS version ## Change logs + +### v0.0.5-a +* Fix cotent padding is not correct on some browsers + ### v0.0.4-a * Add color style to link * Fix some minor bugs \ No newline at end of file diff --git a/About/build/debug/main.css b/About/build/debug/main.css index 94b4ef9..dff9742 100644 --- a/About/build/debug/main.css +++ b/About/build/debug/main.css @@ -4,4 +4,13 @@ afx-app-window[data-id = "About"] a:visited, afx-app-window[data-id = "About"] a:hover { color:#df3154; +} +afx-app-window[data-id = "About"] afx-hbox[data-id="wrapper"] +{ + overflow-x: hidden; + overflow-y:auto; +} +afx-app-window[data-id = "About"] div[data-id="container"] +{ + text-align: justify; } \ No newline at end of file diff --git a/About/build/debug/package.json b/About/build/debug/package.json index 01adecb..2c7471f 100644 --- a/About/build/debug/package.json +++ b/About/build/debug/package.json @@ -6,7 +6,7 @@ "author": "Xuan Sang LE", "email": "xsang.le@gmail.com" }, - "version":"0.0.4-a", + "version":"0.0.5-a", "category":"Other", "iconclass":"fa fa-question-circle", "mimes":["none"], diff --git a/About/build/debug/scheme.html b/About/build/debug/scheme.html index 6521312..625e6bd 100644 --- a/About/build/debug/scheme.html +++ b/About/build/debug/scheme.html @@ -1,10 +1,16 @@ -
- +
+ +
+
+
+
+
+
-
+
\ No newline at end of file diff --git a/About/build/release/About.zip b/About/build/release/About.zip index fba3b802d411bd7a773f6a21f1b851b77ef99d66..6e6a2d14053e316c184531d9f09174ae5ecfcc91 100644 GIT binary patch delta 579 zcmcaCI8jt0z?+$civa|-EjSt=xZ|sIE)xSoF4IJbj>#JsIhYI$CSFwF$xN|TDlbYb zC`c_*nw-ce&uM6&WM`wFl351iNlaY8#|G!g1GP+UWOSW)PnyZdc;fH9ApTB96F!jn z!a50WBp4YOBp4_EW?b&frL3&1P-dWKpl7O^$fc#=mRX^YoL`cfSE5jmn39s2m#&am ztdN&q0u(JON=+_N$j?(K&d*I%NGi%NFHS8g=9;{a$sKHT@Q3EB@j#>F87F^ZS~gja zS;af8LN_BRzaly%u_RF!*$c5;)m#cdkYAQsl$MiUu3KTHkdc{^lA33YDqd-oSXz>A z%~cCDPuUUZU4&W5`FSOYnR&nfftgm4T2Z2#n3I{FXQhx;T3nKuRteOJ9Kf4bFe@{0 zfC7SnXJ_5y%dFQKO*gM*<75Q;01^0;53y@2poSL%11C6^V8k@0$-Erm79d3kpEEFU zz~sU7Rc2sR0v)NBTwEOB&B!Fe0E_C$F&r}HQLIquEHqh&`}P7u6NGtC%&cdhyq-gj IEe-4(0QOjRWdf1yq0kvNBPDZdsgbOD(aBA11TEW1;3GxXXJO+9t$koxs*Hte!CBU1JNrVC6SA-K77&zcs zK#Y4#3=Fx6nR$B2#l`5l6fS6AX8_8BFgwF!EiNAOIm}SySs1E8KG+L%1PJq>*m00` NaxRw~+X{A&C;&SiVm$x= diff --git a/About/css/main.css b/About/css/main.css index 0f4542f..a79510f 100644 --- a/About/css/main.css +++ b/About/css/main.css @@ -3,4 +3,13 @@ afx-app-window[data-id = "About"] a:visited, afx-app-window[data-id = "About"] a:hover { color:#df3154; +} +afx-app-window[data-id = "About"] afx-hbox[data-id="wrapper"] +{ + overflow-x: hidden; + overflow-y:auto; +} +afx-app-window[data-id = "About"] div[data-id="container"] +{ + text-align: justify; } \ No newline at end of file diff --git a/About/package.json b/About/package.json index 01adecb..2c7471f 100644 --- a/About/package.json +++ b/About/package.json @@ -6,7 +6,7 @@ "author": "Xuan Sang LE", "email": "xsang.le@gmail.com" }, - "version":"0.0.4-a", + "version":"0.0.5-a", "category":"Other", "iconclass":"fa fa-question-circle", "mimes":["none"], diff --git a/ActivityMonitor/build/debug/main.js b/ActivityMonitor/build/debug/main.js index 4d83712..22d8e2b 100644 --- a/ActivityMonitor/build/debug/main.js +++ b/ActivityMonitor/build/debug/main.js @@ -1 +1,130 @@ -(function(){var t,i,e;e=this.OS.PM,i=this.OS.application,(t=class extends this.OS.application.BaseApplication{constructor(t){super("ActivityMonitor",t)}main(){var t;return this.scheme.apptitle="Activity Monitor",this.grid=this.find("mygrid"),this.on("btclick",t=>{var i,s,a;if("btkill"===t.id&&(a=this.grid.selectedRow))return s=a.data[0],(i=e.appByPid(s.text))?i.quit(!0):void 0}),t=[{width:50,text:"__(Pid)"},{text:"__(Name)"},{text:"__(Type)",width:80},{width:80,text:"__(Alive (ms))"}],this.gdata={processes:{},alive:[]},this.grid.header=t,this.monitor()}monitor(){var t;return this.gdata.alive=[],t=(new Date).getTime(),$.each(e.processes,(e,s)=>$.each(s,(e,s)=>(this.gdata.processes[s.pid]?(this.gdata.processes[s.pid][3].text=t-s.birth,this.gdata.processes[s.pid][3].domel.update()):(this.gdata.processes[s.pid]=[{text:s.pid},{icon:0===i[s.name].type?i[s.name].meta.icon:s.icon,iconclass:0===i[s.name].type?i[s.name].meta.iconclass:s.iconclass,text:s.name},{text:0===i[s.name].type?"__(Application)":"__(Service)"},{text:t-s.birth}],this.grid.push(this.gdata.processes[s.pid])),this.gdata.alive.push(s.pid)))),$.each(this.gdata.processes,(t,i)=>{if($.inArray(Number(t),this.gdata.alive)<0)return this.grid.delete(this.gdata.processes[t].domel),this.gdata.processes[t]=void 0,delete this.gdata.processes[t]}),this.timer=setTimeout(()=>this.monitor(),500)}cleanup(t){if(this.timer)return clearTimeout(this.timer)}}).singleton=!0,this.OS.register("ActivityMonitor",t)}).call(this); \ No newline at end of file +(function() { + // Copyright 2017-2018 Xuan Sang LE + + // AnTOS Web desktop is is licensed under the GNU General Public + // License v3.0, see the LICENCE file for more information + + // This program is free software: you can redistribute it and/or + // modify it under the terms of the GNU General Public License as + // published by the Free Software Foundation, either version 3 of + // the License, or (at your option) any later version. + + // This program is distributed in the hope that it will be useful, + // but WITHOUT ANY WARRANTY; without even the implied warranty of + // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU + // General Public License for more details. + + // You should have received a copy of the GNU General Public License + //along with this program. If not, see https://www.gnu.org/licenses/. + var ActivityMonitor, _APP, _PM; + + _PM = this.OS.PM; + + _APP = this.OS.application; + + ActivityMonitor = class ActivityMonitor extends this.OS.application.BaseApplication { + constructor(args) { + super("ActivityMonitor", args); + } + + main() { + var header; + this.scheme.apptitle = "Activity Monitor"; + this.grid = this.find("mygrid"); + this.on("btclick", (e) => { + var app, data, item; + if (e.id !== "btkill") { + return; + } + item = this.grid.selectedRow; + if (!item) { + return; + } + data = item.data[0]; + app = _PM.appByPid(data.text); + if (app) { + return app.quit(true); + } + }); + header = [ + { + width: 50, + text: "__(Pid)" + }, + { + text: "__(Name)" + }, + { + text: "__(Type)", + width: 80 + }, + { + width: 80, + text: "__(Alive (ms))" + } + ]; + this.gdata = { + processes: {}, + alive: [] + }; + this.grid.header = header; + return this.monitor(); + } + + monitor() { + var now; + //get all current running process + this.gdata.alive = []; + now = (new Date()).getTime(); + $.each(_PM.processes, (i, d) => { + return $.each(d, (j, a) => { + if (this.gdata.processes[a.pid]) { + this.gdata.processes[a.pid][3].text = now - a.birth; + this.gdata.processes[a.pid][3].domel.update(); //add it + } else { + this.gdata.processes[a.pid] = [ + { + text: a.pid + }, + { + icon: _APP[a.name].type === 0 ? _APP[a.name].meta.icon : a.icon, + iconclass: _APP[a.name].type === 0 ? _APP[a.name].meta.iconclass : a.iconclass, + text: a.name + }, + { + text: _APP[a.name].type === 0 ? "__(Application)" : "__(Service)" + }, + { + text: now - a.birth + } + ]; + this.grid.push(this.gdata.processes[a.pid]); + } + return this.gdata.alive.push(a.pid); + }); + }); + $.each(this.gdata.processes, (i, e) => { + if (($.inArray(Number(i), this.gdata.alive)) < 0) { + this.grid.delete(this.gdata.processes[i].domel); + this.gdata.processes[i] = void 0; + return delete this.gdata.processes[i]; + } + }); + return this.timer = setTimeout((() => { + return this.monitor(); + }), 500); + } + + cleanup(e) { + if (this.timer) { + return clearTimeout(this.timer); + } + } + + }; + + ActivityMonitor.singleton = true; + + this.OS.register("ActivityMonitor", ActivityMonitor); + +}).call(this); diff --git a/packages.json b/packages.json index 7da4445..9cbed91 100644 --- a/packages.json +++ b/packages.json @@ -5,7 +5,7 @@ "description": "https://raw.githubusercontent.com/lxsang/antosdk-apps/master/About/README.md", "category": "Other", "author": "Xuan Sang LE", - "version": "0.0.4-a", + "version": "0.0.5-a", "download": "https://raw.githubusercontent.com/lxsang/antosdk-apps/master/About/build/release/About.zip" }, {