Skip to content

Commit

Permalink
эпопея закончилась!
Browse files Browse the repository at this point in the history
  • Loading branch information
hobbytes committed Mar 21, 2018
1 parent a315914 commit 423ff94
Show file tree
Hide file tree
Showing 4 changed files with 39 additions and 15 deletions.
2 changes: 1 addition & 1 deletion os.php
Original file line number Diff line number Diff line change
Expand Up @@ -23,7 +23,7 @@
$prepare->DisplaySettings();
?>
<body class="ui-body backgroundtheme" style="position:relative; z-index:-2000; overflow-x:hidden; overflow-y:hidden; transition: all 0.5s ease;">
<div id="background-container"><img id="background-wall" src="<?echo $mainwall?>" style="position: absolute; z-index: -99999; width:100%; height:100%; object-fit:cover;"></div>
<div id="background-container"><img id="background-wall" src="<?echo $mainwall?>" style="position: absolute; z-index: -99999; width:100%; height:100%; object-fit:cover; user-select:none;"></div>
<?
if(isset($_SESSION['loginuser'])){
$prepare->welcomescreen();
Expand Down
3 changes: 1 addition & 2 deletions system/apps/Apps_House/main.php
Original file line number Diff line number Diff line change
Expand Up @@ -165,11 +165,10 @@ function wallchange(){
if (is_file($checkApp))
{
$info = file_get_contents('http://'.$_SERVER['HTTP_HOST'].'/system/apps/'.$key['file'].'/main.php?getinfo=true&h='.md5(date('dmyhis')));
//echo $info;
$arrayInfo = json_decode($info);
$curversion = $arrayInfo->{'version'};;
if(empty($curversion)){
//$curversion = '1.0';
$curversion = '1.0';
}
$newversion=$key['version'];
if($newversion>$curversion){
Expand Down
18 changes: 15 additions & 3 deletions system/apps/Explorer/main.php
Original file line number Diff line number Diff line change
Expand Up @@ -102,9 +102,21 @@
$destination = str_replace($linkname,'',$link);
$link = '';
$param = '';
$newname = stristr($destination, 'apps/');
$newname = str_replace(array('apps/','/main.php', '/'),'',$newname);
$puplicname = $newname;
$file = stristr($destination, 'apps/');
$file = str_replace(array('apps/','/main.php', '/'),'',$file);
$info = file_get_contents('http://'.$_SERVER['HTTP_HOST'].'/system/apps/'.$file.'/main.php?getinfo=true&h='.md5(date('dmyhis')));
$arrayInfo = json_decode($info);
if($_SESSION['locale'] == 'en'){
$newname = $arrayInfo->{'name'};
$puplicname = $arrayInfo->{'name'};
}else{
$newname = $arrayInfo->{'secondname'};
$puplicname = $arrayInfo->{'secondname'};
}
if(empty($newname) || empty($puplicname)){
$newname = $file;
$puplicname = $file;
}
$ico = stristr($ico,'?',true);
}else{
if(is_file($link)){
Expand Down
31 changes: 22 additions & 9 deletions system/apps/Settings/appmanager.php
Original file line number Diff line number Diff line change
Expand Up @@ -27,21 +27,22 @@
$app_link = $_GET['app_link'];

if(!empty($app_link)){
$info = file_get_contents('http://'.$_SERVER['HTTP_HOST'].'/system/apps/'.$app_link.'/main.php?getinfo=true&h='.md5(date('dmyhis')));
$arrayInfo = json_decode($info);
if($_SESSION['locale'] == 'en'){
$pubname = $arrayInfo->{'name'};
}else{
$pubname = $arrayInfo->{'secondname'};
}
$file = $_SERVER['DOCUMENT_ROOT'].'/system/users/'.$_SESSION['loginuser'].'/desktop/'.$app_link.'_'.uniqid().'.link';
$fileaction->makelink($file, $_SERVER['DOCUMENT_ROOT'].'/system/apps/'.$app_link.'/', 'main', '', $app_link, $app_link, $app_link, 'system/apps/'.$app_link.'/app.png');
$fileaction->makelink($file, $_SERVER['DOCUMENT_ROOT'].'/system/apps/'.$app_link.'/', 'main', '', $app_link, $pubname, $pubname, 'system/apps/'.$app_link.'/app.png');
}

if(!empty($app_delete) && !in_array($app_delete, $warn_apps)){
$fileaction->deleteDir('../'.$app_delete);
$remove_app = file_get_contents($app_install);
$_remove_app = preg_match('/(?ms)^\['.$app_delete.'](?:(?!^\[[^]\r\n]+]).)*/', $remove_app, $new_file);
$remove_app = str_replace($new_file[0], '', $remove_app);
file_put_contents($app_install, $remove_app);
$gui->newnotification($appname, $language[$_SESSION['locale'].'_name'], $language[$_SESSION['locale'].'_not_1'].': <b>'.$app_delete.'</b> '.$language[$_SESSION['locale'].'_not_2']);
}

$app_array = parse_ini_file($app_install, true);

foreach (glob($_SERVER['DOCUMENT_ROOT']."/system/apps/*/main.php") as $filenames)
{
global $format, $size;
Expand All @@ -59,15 +60,27 @@
$delete_button = '';
}

$version = $app_array[$_app_name]['version'];
$info = file_get_contents('http://'.$_SERVER['HTTP_HOST'].'/system/apps/'.$_app_name.'/main.php?getinfo=true&h='.md5(date('dmyhis')));
$arrayInfo = json_decode($info);

$version = $arrayInfo->{'version'};
if(empty($version)){
$version = $language[$_SESSION['locale'].'_unknow_version'];
}

if($_SESSION['locale'] == 'en'){
$AppName = $arrayInfo->{'name'};
}else{
$AppName = $arrayInfo->{'secondname'};
}
if(empty($AppName)){
$AppName = $app_name;
}

echo'
<div id="'.$_app_name.$appid.'" class="app-container'.$appid.'" style="display:flex; padding:10px; border-bottom:1px solid #ccc; transition:all 0.1s ease-in;">
<div style="background-color:transparent; background-image: url('.$app_icon.'); background-size:cover; height:30px; width:30px; float:left;"></div>
<div style="padding:7px 25px; width:200px; border-right:1px solid #ccc;">'.$app_name.'</div>
<div style="padding:7px 25px; width:200px; border-right:1px solid #ccc;">'.$AppName.'</div>
<div id="button_layer'.$_app_name.$appid.'" class="button_layer" style="opacity:0; display:none; padding:7 10px;">
<div style="float:right;">
<div app-run="'.$_app_name.'" class="ui-forest-accept ui-forest-button ui-forest-center app-run'.$appid.'" >
Expand Down

0 comments on commit 423ff94

Please sign in to comment.