Skip to content

Commit

Permalink
Version 00120; Part of Version 00130
Browse files Browse the repository at this point in the history
### Core / Various
    - Added (path) to listfs() - It can now output the contents of a path directly
    - Removed automatic embedding of helper.css through helper.js - Developers are now supposed to embed both
    - Fixed some SVGs
    - Updated preload.html
    - Updated some outdated links
    - Added dark scrollbar to Darkmode

### CMD
    - Removed toggledevmode command

### Soft Excel
    - Added helper.css

### Explorer
    - Added helper.css
    - Changed from unknown_file.png to unknown_file.svg

### Startmenu
    - Added helper.css

### Hype Chat
    - Added helper.css
    - Added Altbar
    - Changes to CSS

### Notepad
    - Added helper.css

### Paint
    - Added helper.css

### Paint32x32
    - Added helper.css

### Settings
    - Added helper.css

### Simple Cookieclicker
    - Added helper.css

Set Version to 00124
  • Loading branch information
Maingron committed Dec 4, 2019
1 parent fea524c commit d2081b5
Show file tree
Hide file tree
Showing 39 changed files with 526 additions and 299 deletions.
1 change: 1 addition & 0 deletions Program Files/Explorer/Start/exec.html
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,7 @@
<link rel="stylesheet" href="startmenu.css">
<title>Start</title>
<meta charset="UTF-8">
<link rel="stylesheet" href="../../../helper.css">
<script src="../../../helper.js"></script>
<script>

Expand Down
1 change: 1 addition & 0 deletions Program Files/Explorer/inner/exec.html
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,7 @@
<head>
<meta charset="UTF-8">
<link rel="stylesheet" type="text/css" href="explorerstyle.css">
<link rel="stylesheet" href="../../../helper.css">
<script src="../../../helper.js"></script>
</head>

Expand Down
4 changes: 2 additions & 2 deletions Program Files/Explorer/inner/innerexplorer.js
Original file line number Diff line number Diff line change
Expand Up @@ -57,7 +57,7 @@ function explorerdo(nowpath) {
mylistedfile_img.src = "../../../Program%20Files/notepad/icon.png";
}
if (mylistedfile_inner.indexOf(".dat") == mylistedfile_inner.length - 4) {
mylistedfile_img.src = "../../../img/unknown_file.png";
mylistedfile_img.src = "../../../img/unknown_file.svg";
}
if (mylistedfile_inner.indexOf(".xec") == mylistedfile_inner.length - 4) {
mylistedfiles[mylistedfilesnr].setAttribute("onClick", "window.parent.run('" + mylistedfile_inner.split('.xec')[0] + "')");
Expand All @@ -66,7 +66,7 @@ function explorerdo(nowpath) {

if (mylistedfile_inner.indexOf(".del") == mylistedfile_inner.length - 4) {
mylistedfiles[mylistedfilesnr].setAttribute("onClick", "window.parent.formatfs('yes')");
mylistedfile_img.src = "../../../img/unknown_file.png";
mylistedfile_img.src = "../../../img/unknown_file.svg";
}


Expand Down
38 changes: 10 additions & 28 deletions Program Files/cmd/scripts.js
Original file line number Diff line number Diff line change
Expand Up @@ -83,7 +83,6 @@ function runcmd(which) {
return "";
}


if (which.indexOf("setting") == 4) {
which = which.split("cmd:setting ")[1];
which = which.toLowerCase();
Expand All @@ -106,35 +105,18 @@ function runcmd(which) {


if (which.indexOf("help") == 4) {
return "<b class='helpb' style='font-weight:inherit'><b>cls</b> clears console<br><b>echo <a>[Message]</a></b> well, it's echo...<br><b>run <b>[name of program]</b></b> opens a program<br><b>close <b>[pid of program]</b></b> closes a program<br><b>pids </b> lists currently running programs<br><b>exit</b> closes the terminal<br><b>setting <b> [Name of setting] [value]</b></b> changes a setting<br><b>restart</b> restarts MainOS<br><b>toggledev <a>[boolean]</a></b> activates or deactivates the developer mode</b><p style='display:block;line-height:18px'>&nbsp;</p><b class='helpb'>devmode commands:<br><b>js <b>js</b></b> executes js<br>";
return `<b class='helpb' style='font-weight:inherit'><b>cls</b> clears console<br>
<b>echo <a>[Message]</a></b> well, it's echo...<br>
<b>run <b>[name of program]</b></b> opens a program<br>
<b>close <b>[pid of program]</b></b> closes a program<br>
<b>pids </b> lists currently running programs<br><b>exit</b> closes the terminal<br>
<b>setting <b> [Name of setting] [value]</b></b> changes a setting<br>
<b>restart</b> restarts MainOS<br>
</b>
<p style='display:block;line-height:18px'>&nbsp;</p>
<b class='helpb'>devmode commands:<br><b>js <b>js</b></b> executes js<br>`;
}

if (which.indexOf("toggledev") == 4) {
cls = 1;
if (which.indexOf("toggledev 0") == 4 || which.indexOf("toggledev false") == 4) {

window.parent.savefile("C:/mainos/system32/settings/developer.txt", 0, 1, "t=txt");
window.parent.location.reload();
runcmd("cmd:exit");
return ("");

}
if (which.indexOf("toggledev 1") == 4 || which.indexOf("toggledev true") == 4) {
window.parent.savefile("C:/mainos/system32/settings/developer.txt", 1, 1, "t=txt");
window.parent.location.reload();
runcmd("cmd:exit");
return ("");
}

if (window.parent.setting.developer == 0) {
window.parent.savefile("C:/mainos/system32/settings/developer.txt", 1, 1, "t=txt");
} else {
window.parent.savefile("C:/mainos/system32/settings/developer.txt", 0, 1, "t=txt");
}
window.parent.location.reload();
runcmd("cmd:exit");
return ("");
}

if (which.indexOf("toggledownfall") == 4) {
return "<b style='color:#f55; font-weight:inherit'>Command not found. Try /mc:help to get help.</b>";
Expand Down
61 changes: 31 additions & 30 deletions Program Files/colors/exec.html
Original file line number Diff line number Diff line change
Expand Up @@ -2,40 +2,41 @@
<html>
<head>
<meta charset="utf-8">
<link rel="stylesheet" type="text/css" href="imgstyle.css">
<link rel="stylesheet" href="imgstyle.css">
<link rel="stylesheet" href="../../helper.css">
<script src="../../helper.js"></script>
<title>Colors</title>
</head>
<body>
<div id="imgs">
<div style="background-color:red;"></div>
<div style="background-color:green;"></div>
<div style="background-color:yellow;"></div>
<div style="background-color:orange;"></div>
<div style="background-color:blue;"></div>
<div style="background-color:gold;"></div>
<div style="background-color:gray;"></div>
<div style="background-color:grey;"></div>
<div style="background-color:skyblue;"></div>
<div style="background-color:lime;"></div>
<div style="background-color:lightyellow;"></div>
<div style="background-color:black;"></div>
<div style="background-color:beige;"></div>
<div style="background-color:#111;"></div>
<div style="background-color:#222;"></div>
<div style="background-color:#333;"></div>
<div style="background-color:#444;"></div>
<div style="background-color:#555;"></div>
<div style="background-color:#666;"></div>
<div style="background-color:#777;"></div>
<div style="background-color:#888;"></div>
<div style="background-color:#999;"></div>
<div style="background-color:#aaa;"></div>
<div style="background-color:#bbb;"></div>
<div style="background-color:#ccc;"></div>
<div style="background-color:#ddd;"></div>
<div style="background-color:#eee;"></div>
<div style="background-color:brown;"></div>
<div style="background:red;"></div>
<div style="background:green;"></div>
<div style="background:yellow;"></div>
<div style="background:orange;"></div>
<div style="background:blue;"></div>
<div style="background:gold;"></div>
<div style="background:gray;"></div>
<div style="background:grey;"></div>
<div style="background:skyblue;"></div>
<div style="background:lime;"></div>
<div style="background:lightyellow;"></div>
<div style="background:black;"></div>
<div style="background:beige;"></div>
<div style="background:#111;"></div>
<div style="background:#222;"></div>
<div style="background:#333;"></div>
<div style="background:#444;"></div>
<div style="background:#555;"></div>
<div style="background:#666;"></div>
<div style="background:#777;"></div>
<div style="background:#888;"></div>
<div style="background:#999;"></div>
<div style="background:#aaa;"></div>
<div style="background:#bbb;"></div>
<div style="background:#ccc;"></div>
<div style="background:#ddd;"></div>
<div style="background:#eee;"></div>
<div style="background:brown;"></div>
</div>
<!-- <script>parent.notification("Achivement from Colors:","<img src='https://www.minecraftskinstealer.com/achievement/a.php?i=10&h=Achievement+Get%21&t=Open+colors' style='position:relative; width:100%;height:auto;'/>");</script> -->
</body>
</html>
15 changes: 3 additions & 12 deletions Program Files/colors/imgstyle.css
Original file line number Diff line number Diff line change
@@ -1,31 +1,22 @@
* {
transition: 2s;
transition-timing-function: ease-out
}

body {
margin: 0;
background: #000
transition: 2s ease-out;
}

#imgs {
display: flex;
flex-wrap: wrap
flex-wrap: wrap;
}

#imgs div {
display: inline;
position: relative;
top: 0;
width: calc(33.33% - 4px);
margin: 2px;
padding: 0;
height: 33vw;
max-height: 80vh;
float: left;
border-style: none;
border-width: 0;
border-radius: 0;
border: none;
object-fit: cover;
filter: grayscale(.2)
}
Expand Down
150 changes: 150 additions & 0 deletions Program Files/devexample/devexample.css
Original file line number Diff line number Diff line change
@@ -0,0 +1,150 @@
body {
height: 100vh;
}

* {
transition: 0s;
-webkit-touch-callout: none;
-webkit-user-select: none;
-khtml-user-select: none;
-moz-user-select: none;
-ms-user-select: none;
user-select: none;
outline:0px solid transparent;
border:0px solid transparent;

}

#imagep {
position: relative;
display: flex;
top: 0;
left: 0;
height: calc(100% - var(--altbarheight));
width: 100%;
justify-content: center;
align-items: center;
background:var(--beige2);
}

#image {
overflow: hidden;
height: calc(90vmin - var(--altbarheight));
width: calc(90vmin - var(--altbarheight));
display: flex;
position: relative;
flex-wrap: wrap;
align-content: flex-start;
border:1px solid #000;

}

#image button {
margin: 0;
width: 6.25%;
padding:0;
padding-top: 6.25%;
border:0;
background:#fff;
}

#colorselect {
background-color: var(--hovercolor);
z-index: 943;
display: flex;
flex-direction: column;
align-items: center;
position: absolute;
left: 10px;
top: calc(var(--altbarheight) + 10px);
height: auto;
width: auto;
max-height:calc(85vh - var(--altbarheight));
padding-bottom: 3px;
border: 2px solid #000;
}

#colorselect button {
height: 20px;
width: 20px;
margin:0;
padding:0;
border:0;
}

#colorselect #currentcolor {
transition: .5s;
display: block;
border: 2px solid #000;
margin: 3px;
background-color: #000;
height: 40px;
width: 40px;
}

#blue {
background-color: #00f;
}

#blue2 {
background-color: #07f;
}

#yellow {
background-color: #ff0;
}

#green {
background-color: #0f0;
}

#green2 {
background-color:#7a1;
}

#red {
background-color: #f00;
}

#orange {
background-color: #f70;
}

#pink {
background-color:#f0f;
}

#white {
background-color: #fff;
}

#black {
background-color: #000;
}

#gray1 {
background-color: #555;
}

#gray2 {
background-color: #bbb;
}

#brown {
background-color: #7c3e15;
}

@media (prefers-color-scheme:dark) {
#imagep {
background:var(--black);
}

#colorselect {
border-color: var(--themecolor);
background:var(--black3);
}
#imagep #image {
border:2px solid var(--themecolor);
}

}
16 changes: 16 additions & 0 deletions Program Files/devexample/exec.html
Original file line number Diff line number Diff line change
@@ -0,0 +1,16 @@
<!DOCTYPE html>
<html>

<head>
<link rel="stylesheet" href="devexample.css">
<link rel="stylesheet" href="../../helper.css">
<script src="../../helper.js"></script>
<meta charset="UTF-8">
<title>Devexample</title>
</head>

<body>
<div class="altbar"></div>
</body>

</html>
Binary file added Program Files/devexample/icon.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
33 changes: 33 additions & 0 deletions Program Files/devexample/script.js
Original file line number Diff line number Diff line change
@@ -0,0 +1,33 @@
var canvas = document.getElementById("image");
var canvascontent1 = canvas.innerHTML;
var mouseDown = 0;

for(i=0;i<256;i++) {
canvascontent1 = canvascontent1 + "<button onmousedown='paint1(this)' onclick='paint1(this)' onmouseover='paint(this)'></button>";
}

canvas.innerHTML = canvascontent1;

document.body.onmousedown = function() {
mouseDown = 1;
}
document.body.onmouseup = function() {
mouseDown = 0;
}

function paint(thepixel) {
if(mouseDown){
thepixel.style.backgroundColor = color;
}
}

function paint1(thepixel) {
thepixel.style.backgroundColor = color;
}

function clr(clr) {
color = clr;
document.getElementById("currentcolor").style.backgroundColor = color;

}
var color="#000";
Loading

0 comments on commit d2081b5

Please sign in to comment.