Subversion Repositories Kolibri OS

Rev

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

Rev 8129 Rev 8133
Line 1697... Line 1697...
1697
	if (what & PaintWSpeed) CalculateSpeed();
1697
	if (what & PaintWSpeed) CalculateSpeed();
1698
	MenuPaint(what);
1698
	MenuPaint(what);
1699
	SetPicture(picture, (unsigned short)xpar.win, (unsigned short)ypar.win, th);
1699
	SetPicture(picture, (unsigned short)xpar.win, (unsigned short)ypar.win, th);
1700
}
1700
}
Line 1701... Line 1701...
1701
 
1701
 
1702
bool MenuetOnStart(TStartData &me_start, TThreadData th)
1702
bool KolibriOnStart(TStartData &me_start, TThreadData th)
1703
{
1703
{
1704
	randomize();
1704
	randomize();
1705
	me_start.WinData.Title = "Black and white Life";
1705
	me_start.WinData.Title = "Black and white Life";
1706
	me_start.Width = 500; me_start.Height = 400;
1706
	me_start.Width = 500; me_start.Height = 400;
Line 1712... Line 1712...
1712
		OpenFileSetName(open_file_str, CommandLine);
1712
		OpenFileSetName(open_file_str, CommandLine);
1713
	}
1713
	}
1714
	return true;
1714
	return true;
1715
}
1715
}
Line 1716... Line 1716...
1716
 
1716
 
1717
bool MenuetOnClose(TThreadData)
1717
bool KolibriOnClose(TThreadData)
1718
{
1718
{
1719
	SetPictureSize(0, 0);
1719
	SetPictureSize(0, 0);
1720
	SetPoleSize(0, 0);
1720
	SetPoleSize(0, 0);
1721
	return true;
1721
	return true;
Line 1722... Line 1722...
1722
}
1722
}
1723
 
1723
 
1724
int MenuetOnIdle(TThreadData th)
1724
int KolibriOnIdle(TThreadData th)
1725
{
1725
{
1726
	static const unsigned int WAIT_TIME = 2, GEN_TIME = 1;
1726
	static const unsigned int WAIT_TIME = 2, GEN_TIME = 1;
1727
	int res = -1;
1727
	int res = -1;
Line 1786... Line 1786...
1786
		Paint((res < 0 || res > WAIT_TIME) ? (PaintWNull | PaintWNow) : PaintWNull, th);
1786
		Paint((res < 0 || res > WAIT_TIME) ? (PaintWNull | PaintWNow) : PaintWNull, th);
1787
	}
1787
	}
1788
	return res;
1788
	return res;
1789
}
1789
}
Line 1790... Line 1790...
1790
 
1790
 
1791
void MenuetOnSize(int window_rect[], Kolibri::TThreadData th)
1791
void KolibriOnSize(int window_rect[], Kolibri::TThreadData th)
1792
{
1792
{
1793
	unsigned short w, h;
1793
	unsigned short w, h;
1794
	GetClientSize(w, h, window_rect[2], window_rect[3], th);
1794
	GetClientSize(w, h, window_rect[2], window_rect[3], th);
1795
	SetPictureSize(w, h);
1795
	SetPictureSize(w, h);
1796
	generate.paint |= PaintWAll | PaintWFast;
1796
	generate.paint |= PaintWAll | PaintWFast;
1797
	if (!life_data) MenuWinSizeClick(th);
1797
	if (!life_data) MenuWinSizeClick(th);
1798
	Paint(PaintWNull | PaintWNow, th);
1798
	Paint(PaintWNull | PaintWNow, th);
Line 1799... Line 1799...
1799
}
1799
}
1800
 
1800
 
1801
void MenuetOnKeyPress(TThreadData th)
1801
void KolibriOnKeyPress(TThreadData th)
1802
{
1802
{
1803
	int ch;
1803
	int ch;
1804
	while ((ch = GetKey()) >= 0)
1804
	while ((ch = GetKey()) >= 0)
Line 1896... Line 1896...
1896
			}
1896
			}
1897
		}
1897
		}
1898
	}
1898
	}
1899
}
1899
}
Line 1900... Line 1900...
1900
 
1900
 
1901
void MenuetOnMouse(TThreadData th)
1901
void KolibriOnMouse(TThreadData th)
1902
{
1902
{
1903
	short xp = 0, yp = 0;
1903
	short xp = 0, yp = 0;
1904
	int w, h, x, y, xx, yy, m;
1904
	int w, h, x, y, xx, yy, m;
1905
	GetMousePosPicture(xp, yp);
1905
	GetMousePosPicture(xp, yp);