use of run.wallet.iota.ui.RecyclerLayoutManager in project run-wallet-android by runplay.
the class NetworkNodesAddFragment method onViewCreated.
@Override
public void onViewCreated(View view, @Nullable Bundle savedInstanceState) {
super.onViewCreated(view, savedInstanceState);
listNodes.setLayoutManager(new RecyclerLayoutManager(getActivity(), LinearLayoutManager.VERTICAL, false));
((AppCompatActivity) getActivity()).setSupportActionBar(addNodeToolbar);
setHasOptionsMenu(false);
enterPod.setBackgroundColor(B.getColor(getActivity(), AppTheme.getSecondary()));
addNodeToolbar.setNavigationIcon(getResources().getDrawable(R.drawable.md_nav_back));
addNodeToolbar.setNavigationOnClickListener(new View.OnClickListener() {
@Override
public void onClick(View v) {
getActivity().onBackPressed();
}
});
protocol.setOnClickListener(new View.OnClickListener() {
@Override
public void onClick(View view) {
changeProtocol();
}
});
addNodeBtn.setOnClickListener(new View.OnClickListener() {
@Override
public void onClick(View view) {
Nodes.Node node = new Nodes.Node();
node.ip = nodeAddress.getText().toString();
node.port = Sf.toInt(port.getText().toString());
node.protocol = protocol.getText().toString();
node.ip = Utils.stripHttp(node.ip);
if (node.ip.length() > 3 && node.ip.contains(".") && node.port > 0) {
Store.addNode(getActivity(), node.ip, node.port, node.protocol);
getActivity().onBackPressed();
} else {
addressLayout.setError(getString(R.string.messages_enter_neighbor_address));
}
}
});
nodeAddress.addTextChangedListener(new TextWatcher() {
@Override
public void beforeTextChanged(CharSequence s, int start, int count, int after) {
}
@Override
public void onTextChanged(CharSequence s, int start, int before, int count) {
}
@Override
public void afterTextChanged(Editable s) {
// nodeAddress.
addressLayout.setError(null);
}
});
adapter = new AddNodesListAdapter(getActivity(), this);
listNodes.setAdapter(adapter);
}
use of run.wallet.iota.ui.RecyclerLayoutManager in project run-wallet-android by runplay.
the class NetworkNodesFragment method onViewCreated.
@Override
public void onViewCreated(View view, @Nullable Bundle savedInstanceState) {
super.onViewCreated(view, savedInstanceState);
recyclerView.setLayoutManager(new RecyclerLayoutManager(getActivity(), LinearLayoutManager.VERTICAL, false));
nodesTextPod.setBackgroundColor(B.getColor(getActivity(), AppTheme.getSecondary()));
}
use of run.wallet.iota.ui.RecyclerLayoutManager in project run-wallet-android by runplay.
the class WalletAddressesFragment method onViewCreated.
@Override
public void onViewCreated(View view, @Nullable Bundle savedInstanceState) {
super.onViewCreated(view, savedInstanceState);
recyclerView.setLayoutManager(new RecyclerLayoutManager(getActivity(), LinearLayoutManager.VERTICAL, false));
NavigationView navigationView = getActivity().findViewById(R.id.nav_view);
navigationView.getMenu().findItem(R.id.nav_wallet).setChecked(true);
yesButton.setOnClickListener(new View.OnClickListener() {
@Override
public void onClick(View v) {
GetFirstLoadRequestHandler.setUserConfirm(Store.getCurrentSeed().id, true);
confirmPod.setVisibility(View.GONE);
firstLoadPod.setVisibility(View.VISIBLE);
}
});
noButton.setOnClickListener(new View.OnClickListener() {
@Override
public void onClick(View v) {
GetFirstLoadRequestHandler.setUserConfirm(Store.getCurrentSeed().id, false);
confirmPod.setVisibility(View.GONE);
firstLoadPod.setVisibility(View.VISIBLE);
}
});
}
use of run.wallet.iota.ui.RecyclerLayoutManager in project run-wallet-android by runplay.
the class ChooseSeedFragment method onViewCreated.
@Override
public void onViewCreated(View view, @Nullable Bundle savedInstanceState) {
super.onViewCreated(view, savedInstanceState);
recyclerView.setLayoutManager(new RecyclerLayoutManager(getActivity(), LinearLayoutManager.VERTICAL, false));
((AppCompatActivity) getActivity()).setSupportActionBar(chooseSeedToolbar);
setHasOptionsMenu(true);
setAdapter();
fabSeed.setVisibility(View.VISIBLE);
defaultClick.setBackgroundColor(B.getColor(getActivity(), AppTheme.getPrimaryDark()));
setupXchangeBtns();
defaultClick.setOnClickListener(new View.OnClickListener() {
@Override
public void onClick(View v) {
if (Store.getCurrentWallet() != null) {
UiManager.openFragment(getActivity(), WalletTabFragment.class);
}
}
});
}
use of run.wallet.iota.ui.RecyclerLayoutManager in project run-wallet-android by runplay.
the class NetworkNeighborsFragment method onViewCreated.
@Override
public void onViewCreated(View view, @Nullable Bundle savedInstanceState) {
super.onViewCreated(view, savedInstanceState);
recyclerView.setLayoutManager(new RecyclerLayoutManager(getActivity(), LinearLayoutManager.VERTICAL, false));
fabAddButton.setVisibility(View.VISIBLE);
recyclerView.setBackgroundColor(B.getColor(getActivity(), R.color.whiteAlpha75));
revealView.setVisibility(View.INVISIBLE);
isEditTextVisible = false;
}
Aggregations