Skip to content

Commit 10087b5

Browse files
author
Andrew Zenin
committed
Накопительное обновление
1 parent 7750e2b commit 10087b5

21 files changed

+18
-10
lines changed

core/main/additional.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -245,7 +245,7 @@ function saveToStr(&$str){
245245
}
246246

247247
function loadFromStr($data, $format = 'bmp'){
248-
$bitmap = new TBitmap(false);
248+
$bitmap = new TBitmap(nil,false);
249249
picture_loadstr($bitmap->self, $data, $format);
250250
icon_assign($this->self, $bitmap->self);
251251
}

core/main/buttons.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -24,7 +24,7 @@ class TBitBtn extends TControl {
2424
public function get_picture(){
2525

2626
if (!isset($this->_picture)){
27-
$this->_picture = new TBitmap(false);
27+
$this->_picture = new TBitmap(nil,false);
2828
$this->_picture->self = gui_propGet($this->self,'Glyph');
2929
$this->_picture->parent_object = $this->self;
3030
}

core/main/graphics.php

Lines changed: 9 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -460,17 +460,22 @@ class TBitmap extends TGraphic{
460460

461461
public $parent_object = nil;
462462

463-
public function __construct($init=true){
464-
if ($init)
463+
public function __construct($owner=nil, $init=true, $self=nil){
464+
if($self!==nil){
465+
$this->self = $self;
466+
467+
}elseif ($init)
465468
$this->self = tbitmap_create();
469+
if($owner!==nil)
470+
$this->owner = $owner;
466471
}
467472

468473
public function loadFromFile($filename){
469474

470475
$filename = replaceSr(getFileName($filename));
471476

472477
if (fileExt($filename)=='bmp'){
473-
bitmap_loadfile($this->self,replaceSr($filename));
478+
bitmap_loadfile($this->self,$filename);
474479
} else {
475480

476481
convert_file_to_bmp($filename, $this->self);
@@ -620,7 +625,7 @@ function saveToFile($filename){
620625
function getBitmap(){
621626

622627
$self = picture_bitmap($this->self);
623-
$result = new TBitmap(false);
628+
$result = new TBitmap(nil, false);
624629
$result->self = $self;
625630
return $result;
626631
}

core/main/menus.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -86,7 +86,7 @@ class TMenuItem extends TControl {
8686

8787
public function __construct($onwer=nil, $init=true, $self=nil){
8888
parent::__construct($onwer,$init,$self);
89-
$this->picture = new TBitmap(false);
89+
$this->picture = new TBitmap(nil,false);
9090
$this->picture->self = __rtti_link($this->self,'Bitmap');
9191

9292
$this->picture->parent_object = $this->self;

soulEngine.exe

0 Bytes
Binary file not shown.
374 Bytes
Binary file not shown.
-15 KB
Binary file not shown.
-15 KB
Binary file not shown.
374 Bytes
Binary file not shown.
-279 Bytes
Binary file not shown.

0 commit comments

Comments
 (0)