Example #1
0
 private void PageUp_Click(object sender, HtmlElementEventArgs e)
 {
     lock (this)
     {
         detachClick();
         TableInfo info = getTableInfoById(((HtmlElement)sender).Id);
         if (info.mCurrentPage > 1)
         {
             info.mCurrentPage--;
             updateContent(info);
             if (info.ClearData != null)
             {
                 info.ClearData();
             }
             show();
         }
         attachClick();
     }
 }
Example #2
0
 private void PageDown_Click(object sender, HtmlElementEventArgs e)
 {
     lock (this)
     {
         detachClick();
         TableInfo info = getTableInfoById(((HtmlElement)sender).Id);
         bool      remainCurrentPage = false;
         if (info.mCurrentPage == info.mTotalPage && info.mCurrentContent.Count < info.mRowsPerPage)
         {
             remainCurrentPage = true;
         }
         if (!remainCurrentPage)
         {
             info.mCurrentPage++;
         }
         updateContent(info);
         if (info.ClearData != null)
         {
             info.ClearData();
         }
         show();
         attachClick();
     }
 }