mirror of
https://github.com/nextcloud/android.git
synced 2024-11-27 17:46:37 +03:00
butterknife for details fragment + proper empty content handling
This commit is contained in:
parent
b3d3d3c047
commit
7df8a18d6b
2 changed files with 60 additions and 0 deletions
|
@ -36,6 +36,7 @@ import android.widget.ProgressBar;
|
|||
import com.owncloud.android.R;
|
||||
import com.owncloud.android.datamodel.FileDataStorageManager;
|
||||
import com.owncloud.android.datamodel.OCFile;
|
||||
import com.owncloud.android.datamodel.ThumbnailsCacheManager;
|
||||
import com.owncloud.android.utils.ThemeUtils;
|
||||
|
||||
/**
|
||||
|
|
|
@ -38,6 +38,7 @@ import android.view.View.OnClickListener;
|
|||
import android.view.ViewGroup;
|
||||
import android.widget.ImageButton;
|
||||
import android.widget.ImageView;
|
||||
import android.widget.LinearLayout;
|
||||
import android.widget.PopupMenu;
|
||||
import android.widget.ProgressBar;
|
||||
import android.widget.TextView;
|
||||
|
@ -67,6 +68,10 @@ import java.lang.ref.WeakReference;
|
|||
import butterknife.BindView;
|
||||
import butterknife.ButterKnife;
|
||||
import butterknife.Unbinder;
|
||||
import butterknife.BindView;
|
||||
import butterknife.ButterKnife;
|
||||
import butterknife.Optional;
|
||||
import butterknife.Unbinder;
|
||||
|
||||
/**
|
||||
* This Fragment is used to display the details about a file.
|
||||
|
@ -123,6 +128,60 @@ public class FileDetailFragment extends FileFragment implements OnClickListener
|
|||
private ToolbarActivity activity;
|
||||
private int activeTab;
|
||||
|
||||
@Nullable @BindView(R.id.fdProgressBlock)
|
||||
View downloadProgressContainer;
|
||||
|
||||
@Nullable @BindView(R.id.fdCancelBtn)
|
||||
ImageButton cancelButton;
|
||||
|
||||
@Nullable @BindView(R.id.fdProgressBar)
|
||||
ProgressBar progressBar;
|
||||
|
||||
@Nullable @BindView(R.id.fdProgressText)
|
||||
TextView progressText;
|
||||
|
||||
@Nullable @BindView(R.id.fdFilename)
|
||||
TextView fileName;
|
||||
|
||||
@Nullable @BindView(R.id.fdSize)
|
||||
TextView fileSize;
|
||||
|
||||
@Nullable @BindView(R.id.fdModified)
|
||||
TextView fileModifiedTimestamp;
|
||||
|
||||
@Nullable @BindView(R.id.fdFavorite)
|
||||
ImageView favoriteIcon;
|
||||
|
||||
@Nullable @BindView(R.id.overflow_menu)
|
||||
ImageView overflowMenu;
|
||||
|
||||
@Nullable @BindView(R.id.tab_layout)
|
||||
TabLayout tabLayout;
|
||||
|
||||
@Nullable @BindView(R.id.pager)
|
||||
ViewPager viewPager;
|
||||
|
||||
@Nullable @BindView(R.id.empty_list_view_text)
|
||||
protected TextView emptyContentMessage;
|
||||
|
||||
@Nullable @BindView(R.id.empty_list_view_headline)
|
||||
protected TextView emptyContentHeadline;
|
||||
|
||||
@Nullable @BindView(R.id.empty_list_icon)
|
||||
protected ImageView emptyContentIcon;
|
||||
|
||||
@Nullable @BindView(R.id.empty_list_progress)
|
||||
protected ProgressBar emptyProgressBar;
|
||||
|
||||
private int layout;
|
||||
private View view;
|
||||
private boolean previewLoaded;
|
||||
private Account account;
|
||||
private Unbinder unbinder;
|
||||
|
||||
public ProgressListener progressListener;
|
||||
private ToolbarActivity activity;
|
||||
|
||||
/**
|
||||
* Public factory method to create new FileDetailFragment instances.
|
||||
*
|
||||
|
|
Loading…
Reference in a new issue