From 041293ee9385cdabe84ed4b5238cb4633311861c Mon Sep 17 00:00:00 2001 From: Xuan Sang LE Date: Thu, 4 Jan 2018 11:51:12 +0100 Subject: [PATCH] add screenshot --- README.md | 8 +++++++- src/core/core.coffee | 8 ++++++++ src/core/gui.coffee | 10 ++-------- src/core/tags/afx-file-view.js | 2 ++ 4 files changed, 19 insertions(+), 9 deletions(-) diff --git a/README.md b/README.md index 62d4be8..6cac99b 100644 --- a/README.md +++ b/README.md @@ -1,2 +1,8 @@ # antos -Simple web os (client side) based on jQuery and Riot, it is intended to be used along with our antd server and Lua based server side app +Simple web os (client side) based on jQuery and Riot, it is designed to be used along with our antd server and Lua based server side app, but can be adapted to be used with any server side languages (PHP, etc) and server, by implementing all the system calls API defined in core/handlers/RemoteHandler.coffee. Basically, application design for the web os (Applications/) rely on these system calls for communicating with the server. In doing so, the entire application can be developped with coffee/javascript/css without the need of a server side script. + +Note that, the development of the project is in early alpha state, so bugs are very welcome :) + +![Screenshot](screenshot.png "Screenshot") + + diff --git a/src/core/core.coffee b/src/core/core.coffee index ac28d9d..9109249 100644 --- a/src/core/core.coffee +++ b/src/core/core.coffee @@ -79,6 +79,14 @@ self.OS or= tmp.push a for a in _PM.processes[app] a.quit() for a in tmp + cleanup: -> + ($ "#wrapper").empty() + _GUI.clearTheme() + _courrier.observable = riot.observable() + _OS.APP = {} + _PM.processes = {} + _PM.pidalloc = 0 + boot: -> #first login _API.handler.auth (d) -> diff --git a/src/core/gui.coffee b/src/core/gui.coffee index db49532..5babe75 100644 --- a/src/core/gui.coffee +++ b/src/core/gui.coffee @@ -141,8 +141,7 @@ self.OS.GUI = alert "System fall: Cannot init desktop manager" login: () -> - ($ "#wrapper").empty() - _GUI.clearTheme() + _OS.cleanup() _API.resource "schemes/login.html", (x) -> return null unless x scheme = $.parseHTML x @@ -158,12 +157,7 @@ self.OS.GUI = alert "System fall: Cannot init login screen" startAntOS: (conf) -> - ($ "#wrapper").empty() - _GUI.clearTheme() - _courrier.observable = riot.observable() - _OS.APP = {} - _PM.processes = {} - _PM.pidalloc = 0 + _OS.cleanup() _OS.setting.applications = conf.applications if conf.applications _OS.setting.appearance = conf.appearance if conf.appearance _OS.setting.user = conf.user diff --git a/src/core/tags/afx-file-view.js b/src/core/tags/afx-file-view.js index 45964b1..bd3c3cc 100644 --- a/src/core/tags/afx-file-view.js +++ b/src/core/tags/afx-file-view.js @@ -29,6 +29,8 @@ self[k] = v if(k == 'view') switchView() + if(k == "data") + self.selectedFile = undefined self.update() } self.root.get = function(k)