示例#1
0
 @Override
 public void onChanged() {
   super.onChanged();
   int count = mAdapter.getCount();
   mContainer.removeAllViews();
   if (count < 1) {
     requestLayout();
     return;
   }
   if (count == 1) {
     View view = mAdapter.getView(0);
     mContainer.addView(view, mLinearLayoutParams);
     requestLayout();
     return;
   }
   int position = count - 1;
   View view = mAdapter.getView(position);
   mContainer.addView(view, mLinearLayoutParams);
   for (position = 0; position < count; position++) {
     view = mAdapter.getView(position);
     mContainer.addView(view, mLinearLayoutParams);
   }
   view = mAdapter.getView(0);
   mContainer.addView(view, mLinearLayoutParams);
   requestLayout();
   scrollToPage(0, false);
 }
 /** Notifies observers about data changing */
 protected void notifyDataChangedEvent() {
   if (datasetObservers != null) {
     for (DataSetObserver observer : datasetObservers) {
       observer.onChanged();
     }
   }
 }
    @Override
    public void onChanged() {
      Log.i(LOG_TAG, "onChanged");
      super.onChanged();

      resetList();
      reloadAdapter();
    }
 @Override
 public void onChanged() {
   super.onChanged();
   mDataValid = true;
   notifyDataSetChanged();
 }
 @Override
 public void onChanged() {
   Log.i(TAG, "WorkspaceDataSetObserver::onChanged");
   super.onChanged();
 }
示例#6
0
 private void notifyObserver() {
   if (null != datasetObserver) {
     datasetObserver.onChanged();
   }
 }
 /** Notify registered observers of changes. */
 private void notifyObservers() {
   for (DataSetObserver dso : observers) {
     dso.onChanged();
   }
 }
 @Override
 public void onChanged() {
   super.onChanged();
   mHasChanged = true;
 }