Subversion Repositories Kolibri OS

Rev

Rev 7422 | Rev 7507 | Go to most recent revision | Show entire file | Regard whitespace | Details | Blame | Last modification | View Log | RSS feed

Rev 7422 Rev 7506
Line 43... Line 43...
43
 
43
 
44
unsigned char icons[] = FROM "icons.raw";
44
unsigned char icons[] = FROM "icons.raw";
45
#define TOPPANELH 68
45
#define TOPPANELH 68
Line 46... Line 46...
46
#define BOTPANELH 26
46
#define BOTPANELH 26
47
 
47
 
48
char new_disk_size[5];
48
char new_disk_size[7];
Line 49... Line 49...
49
edit_box edit_disk_size= {50,0,7,0xffffff,0x94AECE,0xFFFfff,0xffffff,0x10000000,
49
edit_box edit_disk_size= {50,0,7,0xffffff,0x94AECE,0xFFFfff,0xffffff,0x10000000,
50
	4,#new_disk_size,0, 1000000000000010b};
50
	sizeof(new_disk_size)-2,#new_disk_size,0, ed_focus+ed_figure_only};
51
 
51
 
52
void Main_Window()
52
void Main_Window()
Line 167... Line 167...
167
{
167
{
168
	int fr;
168
	int fr;
169
	fr = GetFreeRAM() / 5 * 2;
169
	fr = GetFreeRAM() / 5 * 2;
170
	fr = itoa(fr / 2048);
170
	fr = itoa(fr / 2048);
171
	strcpy(#new_disk_size, fr);
171
	strcpy(#new_disk_size, fr);
172
	edit_disk_size.size = edit_disk_size.pos = strlen(#new_disk_size);
172
	EditBox_UpdateText(#edit_disk_size, edit_disk_size.flags);
173
	edit_box_draw stdcall (#edit_disk_size);
173
	edit_box_draw stdcall (#edit_disk_size);
174
}
174
}
Line 175... Line 175...
175
 
175
 
Line 241... Line 241...
241
		WriteText(disk_pos_x[i]+26,disk_pos_y[i]+6,  10110000b, 0x222222, #disk_list[i].Item);
241
		WriteText(disk_pos_x[i]+26,disk_pos_y[i]+6,  10110000b, 0x222222, #disk_list[i].Item);
242
		real_id = disk_list[i].Item[3] - '0';
242
		real_id = disk_list[i].Item[3] - '0';
243
		WriteText(disk_pos_x[i]+27,disk_pos_y[i]+24, 0x80, 0x555555, ConvertSize(disk_sizes[real_id]));
243
		WriteText(disk_pos_x[i]+27,disk_pos_y[i]+24, 0x80, 0x555555, ConvertSize(disk_sizes[real_id]));
244
		_PutImage(disk_pos_x[i]+6,disk_pos_y[i]+6, 14,14, 2*14*14*3+#icons);
244
		_PutImage(disk_pos_x[i]+6,disk_pos_y[i]+6, 14,14, 2*14*14*3+#icons);
245
		if (selected==i) {
245
		if (selected==i) {
246
			if ( !asm test edit_disk_size.flags, 2) selection_color = selection_active; else selection_color = selection_inactive;
246
			if ( edit_disk_size.flags & ed_focus) selection_color = selection_inactive; else selection_color = selection_active;
247
			DrawWideRectangle(disk_pos_x[i], disk_pos_y[i], 80, 40, 2, selection_color);
247
			DrawWideRectangle(disk_pos_x[i], disk_pos_y[i], 80, 40, 2, selection_color);
248
			PutPixel(disk_pos_x[i], disk_pos_y[i], 0xFFFfff);
248
			PutPixel(disk_pos_x[i], disk_pos_y[i], 0xFFFfff);
249
		}
249
		}
250
	}
250
	}
251
}
251
}