void Square::IncreaseRow(int increaseNo) { int newRow = m_row + increaseNo; if(newRow > Settings::NoOfRows) { return; } m_row = newRow; SetPixelPosition(m_coll, m_row); }
void Square::IncreaseColl(int increaseNo) { int newColl = m_coll + increaseNo; if(newColl < 0 || newColl > Settings::NoOfColls) { return; } m_coll = newColl; SetPixelPosition(m_coll, m_row); }
//------------------------------------------------------------------------------ uint32 CGUIWidget::OnDragProcess( CGUIEventDrag* pEvent ) { //call callback function CallbackFunction("OnDragProcess", pEvent); if( pEvent->IsExpired() == false) { SetPixelPosition(pEvent->GetWidgetLocalPos()); Refresh(); } if( IsMouseConsumed()) { pEvent->Consume( true ); } return 0; }
void Square::SetPosition(int coll, int row) { m_coll = coll; m_row = row; SetPixelPosition(m_coll, m_row); }