@Override
  public void onCreateOptionsMenu(final Menu menu, MenuInflater inflater) {
    super.onCreateOptionsMenu(menu, inflater);
    // inflater.inflate(R.menu.menu_main, menu);

    try {
      menu.add(1, 99, 1, "help")
          .setIcon(R.drawable.help_icon)
          .setShowAsAction(MenuItem.SHOW_AS_ACTION_ALWAYS);

      final MenuItem action_help = menu.findItem(R.id.action_help);
      menu.findItem(R.id.action_help).setVisible(true);
      action_help.setOnMenuItemClickListener(
          new MenuItem.OnMenuItemClickListener() {
            @Override
            public boolean onMenuItemClick(MenuItem item) {
              menu.findItem(R.id.action_help).setVisible(false);
              return false;
            }
          });

    } catch (Exception e) {

    }
  }
 @Override
 public void onCreateOptionsMenu(Menu menu, MenuInflater inflater) {
   super.onCreateOptionsMenu(menu, inflater);
   menu.add(0, SessionConstantsAssetUser.IC_ACTION_USER_HELP_REDEEM, 0, "help")
       .setIcon(R.drawable.dap_asset_user_help_icon)
       .setShowAsAction(MenuItem.SHOW_AS_ACTION_ALWAYS);
 }
  @Override
  public void onCreate(Bundle savedInstanceState) {
    super.onCreate(savedInstanceState);

    try {
      CryptoCustomerWalletModuleManager moduleManager =
          ((CryptoCustomerWalletSession) appSession).getModuleManager();
      walletManager = moduleManager.getCryptoCustomerWallet(appSession.getAppPublicKey());
      errorManager = appSession.getErrorManager();

      Object data = appSession.getData(CryptoCustomerWalletSession.LOCATION_LIST);
      if (data == null) {
        locationList = new ArrayList<>();
        appSession.setData(CryptoCustomerWalletSession.LOCATION_LIST, locationList);
      } else {
        locationList = (List<String>) data;
      }
      if (locationList.size() > 0) {
        int pos = locationList.size() - 1;
        if (locationList.get(pos).equals("settings") || locationList.get(pos).equals("wizard")) {
          locationList.remove(pos);
        }
      }
    } catch (Exception ex) {
      Log.e(TAG, ex.getMessage(), ex);
      if (errorManager != null)
        errorManager.reportUnexpectedWalletException(
            Wallets.CBP_CRYPTO_BROKER_WALLET,
            UnexpectedWalletExceptionSeverity.DISABLES_THIS_FRAGMENT,
            ex);
    }
  }
  @Override
  public void onCreate(Bundle savedInstanceState) {
    super.onCreate(savedInstanceState);
    try {

      setHasOptionsMenu(true);
      // setting up  module
      moduleManager = appSession.getModuleManager();
      errorManager = appSession.getErrorManager();

      mNotificationsCount =
          moduleManager
              .listCryptoBrokersPendingLocalAction(
                  moduleManager.getSelectedActorIdentity(), MAX, offset)
              .size();

      // TODO: display unread notifications.
      new FetchCountTask().execute();

    } catch (Exception ex) {
      CommonLogger.exception(TAG, ex.getMessage(), ex);
      errorManager.reportUnexpectedUIException(
          UISource.ACTIVITY, UnexpectedUIExceptionSeverity.CRASH, ex);
    }
  }
  @Override
  public void onCreateOptionsMenu(Menu menu, MenuInflater inflater) {

    super.onCreateOptionsMenu(menu, inflater);

    menu.add(0, Constants.SELECT_IDENTITY, 0, "send")
        .setIcon(R.drawable.ic_actionbar_send)
        .setShowAsAction(MenuItem.SHOW_AS_ACTION_ALWAYS);
  }
Exemple #6
0
 @Override
 public void onCreate(Bundle savedInstanceState) {
   super.onCreate(savedInstanceState);
   try {
     manager = ((AssetUserSession) appSession).getWalletManager();
   } catch (Exception ex) {
     ex.printStackTrace();
   }
 }
 @Override
 public void onCreate(Bundle savedInstanceState) {
   super.onCreate(savedInstanceState);
   setHasOptionsMenu(true);
   intraUserSubAppSession = ((IntraUserSubAppSession) appSession);
   moduleManager = intraUserSubAppSession.getModuleManager();
   errorManager = appSession.getErrorManager();
   lstIntraUserInformations = new ArrayList<>();
 }
  @Override
  public void onCreate(Bundle savedInstanceState) {
    super.onCreate(savedInstanceState);

    // setting up  module
    artistCommunityInformation = (ArtistCommunityInformation) appSession.getData(ACTOR_SELECTED);
    moduleManager = appSession.getModuleManager();
    errorManager = appSession.getErrorManager();
    artistCommunityInformations = new ArrayList<>();
  }
  @Override
  public void onCreateContextMenu(
      ContextMenu menu, View view, ContextMenu.ContextMenuInfo menuInfo) {
    menu.setHeaderTitle("Choose mode");
    menu.setHeaderIcon(getActivity().getResources().getDrawable(R.drawable.ic_camera_green));
    menu.add(Menu.NONE, CONTEXT_MENU_CAMERA, Menu.NONE, "Camera");
    menu.add(Menu.NONE, CONTEXT_MENU_GALLERY, Menu.NONE, "Gallery");

    super.onCreateContextMenu(menu, view, menuInfo);
  }
 @Override
 public void onCreate(Bundle savedInstanceState) {
   super.onCreate(savedInstanceState);
   setHasOptionsMenu(true);
   try {
     manager = ((AssetIssuerCommunitySubAppSession) appSession).getModuleManager();
     errorManager = appSession.getErrorManager();
   } catch (Exception ex) {
     ex.printStackTrace();
   }
 }
 @Override
 public void onViewCreated(View view, Bundle savedInstanceState) {
   super.onViewCreated(view, savedInstanceState);
   if (swipeRefreshLayout != null)
     swipeRefreshLayout.post(
         new Runnable() {
           @Override
           public void run() {
             onRefresh();
           }
         });
 }
  @Override
  public void onCreate(Bundle savedInstanceState) {
    super.onCreate(savedInstanceState);
    setHasOptionsMenu(true);

    assetUserSession = (AssetUserSession) appSession;
    moduleManager = assetUserSession.getModuleManager();
    errorManager = appSession.getErrorManager();

    settingsManager = appSession.getModuleManager().getSettingsManager();

    configureToolbar();
  }
Exemple #13
0
  @Override
  public void onViewCreated(View view, Bundle savedInstanceState) {
    super.onViewCreated(view, savedInstanceState);
    FermatWorker worker =
        new FermatWorker() {
          @Override
          protected Object doInBackground() throws Exception {
            if (manager == null)
              throw new NullPointerException("AssetUserWalletModuleManager is null");
            assetUserWalletList = manager.getAssetUserWalletBalances("walletPublicKeyTest");
            if (assetUserWalletList != null && !assetUserWalletList.isEmpty()) {
              bookAssets = new ArrayList<>();
              for (AssetUserWalletList assetUserWallet : assetUserWalletList) {
                DigitalAsset asset =
                    new DigitalAsset(
                        assetUserWallet.getDigitalAsset().getName(),
                        String.valueOf(
                            String.format(
                                "BookBalance: %d - AvailableBalance: %d",
                                assetUserWallet.getQuantityBookBalance(),
                                assetUserWallet.getQuantityAvailableBalance())));
                asset.setAssetPublicKey(assetUserWallet.getDigitalAsset().getPublicKey());
                asset.setWalletPublicKey("public_key");
                bookAssets.add(asset);
              }
            }
            return true;
          }
        };
    worker.setContext(getActivity());
    worker.setCallBack(
        new FermatWorkerCallBack() {
          @Override
          public void onPostExecute(Object... result) {
            if (getActivity() != null) {
              if (bookAssets != null && !bookAssets.isEmpty()) {
                if (adapter != null) adapter.changeDataSet(bookAssets);
              }
            }
          }

          @Override
          public void onErrorOccurred(Exception ex) {
            if (getActivity() != null)
              Toast.makeText(getActivity(), ex.getMessage(), Toast.LENGTH_LONG).show();
            CommonLogger.exception(this.getClass().getName(), ex.getMessage(), ex);
            ex.printStackTrace();
          }
        });
    worker.execute();
  }
  @Override
  public void onCreate(Bundle savedInstanceState) {
    super.onCreate(savedInstanceState);

    try {
      tokenlyFanUserIdentitySubAppSession = (TokenlyFanUserIdentitySubAppSession) appSession;
      moduleManager = tokenlyFanUserIdentitySubAppSession.getModuleManager();
      errorManager = appSession.getErrorManager();
      setHasOptionsMenu(false);
      settingsManager = tokenlyFanUserIdentitySubAppSession.getModuleManager().getSettingsManager();

      try {
        if (tokenlyFanUserIdentitySubAppSession.getAppPublicKey() != null) {
          tokenlyFanPreferenceSettings =
              settingsManager.loadAndGetSettings(
                  tokenlyFanUserIdentitySubAppSession.getAppPublicKey());
        } else {
          // TODO: Joaquin: Lo estoy poniendo con un public key hardcoded porque en este punto no
          // posee public key.
          tokenlyFanPreferenceSettings = settingsManager.loadAndGetSettings("123456789");
        }

      } catch (Exception e) {
        tokenlyFanPreferenceSettings = null;
      }

      if (tokenlyFanPreferenceSettings == null) {
        tokenlyFanPreferenceSettings = new TokenlyFanPreferenceSettings();
        tokenlyFanPreferenceSettings.setIsPresentationHelpEnabled(false);
        if (settingsManager != null) {
          if (tokenlyFanUserIdentitySubAppSession.getAppPublicKey() != null) {
            settingsManager.persistSettings(
                tokenlyFanUserIdentitySubAppSession.getAppPublicKey(),
                tokenlyFanPreferenceSettings);
          } else {
            settingsManager.persistSettings("123456789", tokenlyFanPreferenceSettings);
          }
        }
      }

      //            if(moduleManager.getAllIntraWalletUsersFromCurrentDeviceUser().isEmpty()){
      //                moduleManager.createNewIntraWalletUser("John Doe", null);
      //            }
    } catch (Exception ex) {
      errorManager.reportUnexpectedSubAppException(
          SubApps.TKY_FAN_IDENTITY_SUB_APP,
          UnexpectedSubAppExceptionSeverity.DISABLES_THIS_FRAGMENT,
          ex);
    }
  }
  @Override
  public void onCreate(Bundle savedInstanceState) {
    super.onCreate(savedInstanceState);

    try {
      issuerIdentitySubAppSession = (IssuerIdentitySubAppSession) appSession;
      moduleManager = issuerIdentitySubAppSession.getModuleManager();
      errorManager = appSession.getErrorManager();

      //            if(moduleManager.getIdentityAssetIssuersFromCurrentDeviceUser().isEmpty()){
      //                moduleManager.createNewIdentityAssetIssuer("Asset Issuer John Doe", null);
      //            }
    } catch (Exception ex) {
      CommonLogger.exception(TAG, ex.getMessage(), ex);
    }
  }
  @Override
  public void onCreate(Bundle savedInstanceState) {
    super.onCreate(savedInstanceState);
    setHasOptionsMenu(true);

    try {
      redeemPointIdentitySubAppSession = (RedeemPointIdentitySubAppSession) appSession;
      moduleManager = redeemPointIdentitySubAppSession.getModuleManager();
      errorManager = appSession.getErrorManager();
      settingsManager = appSession.getModuleManager().getSettingsManager();

      try {
        if (appSession.getAppPublicKey() != null) {
          redeemPointSettings = settingsManager.loadAndGetSettings(appSession.getAppPublicKey());
        }
      } catch (Exception e) {
        redeemPointSettings = null;
      }

      if (redeemPointSettings == null) {
        redeemPointSettings = new RedeemPointSettings();
        redeemPointSettings.setIsPresentationHelpEnabled(true);
        if (appSession.getAppPublicKey() != null) {
          settingsManager.persistSettings(appSession.getAppPublicKey(), redeemPointSettings);
        }
      }

      if (moduleManager.getIdentityAssetRedeemPoint() == null) {

        final RedeemPointSettings redeemPointSettingsTemp = redeemPointSettings;

        Handler handlerTimer = new Handler();
        handlerTimer.postDelayed(
            new Runnable() {
              public void run() {
                if (redeemPointSettingsTemp.isPresentationHelpEnabled()) {
                  setUpPresentation(false);
                }
              }
            },
            500);
      }
    } catch (Exception ex) {
      CommonLogger.exception(TAG, ex.getMessage(), ex);
    }
  }
  @Override
  public void onCreate(Bundle savedInstanceState) {
    super.onCreate(savedInstanceState);
    try {
      referenceWalletSession = (ReferenceAppFermatSession) appSession;
      errorManager = appSession.getErrorManager();

      errorManager = appSession.getErrorManager();
      toolbar = getToolbar();
      toolbar.setNavigationIcon(getResources().getDrawable(R.drawable.cht_ic_back_buttom));
    } catch (Exception e) {
      if (errorManager != null)
        errorManager.reportUnexpectedSubAppException(
            SubApps.CHT_CHAT,
            UnexpectedSubAppExceptionSeverity.DISABLES_SOME_FUNCTIONALITY_WITHIN_THIS_FRAGMENT,
            e);
    }
  }
Exemple #18
0
  @Override
  public void onViewCreated(View view, Bundle savedInstanceState) {
    super.onViewCreated(view, savedInstanceState);

    lv = (ExpandableListView) view.findViewById(R.id.expListView);
    lv.setAdapter(new ExpandableListAdapter(contacts, transactions));
    lv.setGroupIndicator(null);

    lv.setOnItemClickListener(null);

    /*  lv.setOnChildClickListener(new ExpandableListView.OnChildClickListener() {

        @Override
        public boolean onChildClick(ExpandableListView parent, View v, int groupPosition, int childPosition, long id) {

            Intent intent;
             intent = new Intent(getActivity(), SentDetailActivity.class);
            startActivity(intent);

            return true;
        }
    });*/

    lv.setOnGroupClickListener(
        new ExpandableListView.OnGroupClickListener() {

          @Override
          public boolean onGroupClick(
              ExpandableListView parent, View v, int groupPosition, long id) {

            /* Intent intent;
            intent = new Intent(getActivity(), ReceiveFromNewContactActivity.class);
            startActivity(intent);*/
            //                    Intent intent;
            //
            // appRuntimeMiddleware.getActivity(Activities.CWP_WALLET_RUNTIME_ADULTS_ALL_CONTACTS_NEW_RECEIVE);
            //                    intent = new Intent(getActivity(),
            // com.bitdubai.android_core.app.FragmentActivity.class);
            //                    startActivity(intent);
            return groupPosition == 0;
          }
        });
  }
  @Override
  public View onCreateView(
      LayoutInflater inflater, ViewGroup container, Bundle savedInstanceState) {
    super.onCreateView(inflater, container, savedInstanceState);

    View layout = inflater.inflate(R.layout.ccw_settings_my_locations, container, false);

    adapter = new LocationsAdapter(getActivity(), locationList);
    adapter.setDeleteButtonListener(this);

    recyclerView = (RecyclerView) layout.findViewById(R.id.ccw_selected_locations_recycler_view);
    recyclerView.setLayoutManager(
        new LinearLayoutManager(getActivity(), LinearLayoutManager.VERTICAL, false));
    recyclerView.setAdapter(adapter);

    emptyView = layout.findViewById(R.id.ccw_selected_locations_empty_view);

    final View addLocationButton = layout.findViewById(R.id.ccw_add_location_button);
    addLocationButton.setOnClickListener(
        new View.OnClickListener() {
          @Override
          public void onClick(View view) {

            locationList.add("settings");
            changeActivity(
                Activities.CBP_CRYPTO_CUSTOMER_WALLET_CREATE_NEW_LOCATION_IN_SETTINGS,
                appSession.getAppPublicKey());
          }
        });

    final View nextStepButton = layout.findViewById(R.id.ccw_next_step_button);
    nextStepButton.setOnClickListener(
        new View.OnClickListener() {
          @Override
          public void onClick(View view) {
            saveSettingAndGoNextStep();
          }
        });

    showOrHideRecyclerView();

    return layout;
  }
 @Override
 public void onActivityResult(int requestCode, int resultCode, Intent data) {
   if (resultCode == Activity.RESULT_OK) {
     switch (requestCode) {
       case REQUEST_IMAGE_CAPTURE:
         Bundle extras = data.getExtras();
         cryptoCustomerBitmap = (Bitmap) extras.get("data");
         break;
       case REQUEST_LOAD_IMAGE:
         Uri selectedImage = data.getData();
         try {
           if (isAttached) {
             ContentResolver contentResolver = getActivity().getContentResolver();
             cryptoCustomerBitmap =
                 MediaStore.Images.Media.getBitmap(contentResolver, selectedImage);
             cryptoCustomerBitmap =
                 Bitmap.createScaledBitmap(
                     cryptoCustomerBitmap,
                     mCustomerImage.getWidth(),
                     mCustomerImage.getHeight(),
                     true);
             Picasso.with(getActivity())
                 .load(selectedImage)
                 .transform(new CircleTransform())
                 .into(mCustomerImage);
           }
         } catch (Exception e) {
           e.printStackTrace();
           Toast.makeText(
                   getActivity().getApplicationContext(),
                   "Error cargando la imagen",
                   Toast.LENGTH_SHORT)
               .show();
         }
         break;
     }
   }
   getActivity()
       .getWindow()
       .setSoftInputMode(WindowManager.LayoutParams.SOFT_INPUT_STATE_ALWAYS_VISIBLE);
   super.onActivityResult(requestCode, resultCode, data);
 }
  @Override
  public void onActivityResult(int requestCode, int resultCode, Intent data) {
    super.onActivityResult(requestCode, resultCode, data);
    if (resultCode == Activity.RESULT_OK) {
      Bitmap imageBitmap = null;
      ImageView pictureView = mIdentityImage;

      switch (requestCode) {
        case REQUEST_IMAGE_CAPTURE:
          Bundle extras = data.getExtras();
          imageBitmap = (Bitmap) extras.get("data");
          break;
        case REQUEST_LOAD_IMAGE:
          Uri selectedImage = data.getData();
          try {
            if (isAttached) {
              ContentResolver contentResolver = getActivity().getContentResolver();
              imageBitmap = MediaStore.Images.Media.getBitmap(contentResolver, selectedImage);
              imageBitmap =
                  Bitmap.createScaledBitmap(
                      imageBitmap, pictureView.getWidth(), pictureView.getHeight(), true);
              brokerImageByteArray = toByteArray(imageBitmap);
            }
          } catch (Exception e) {
            e.printStackTrace();
            Toast.makeText(
                    getActivity().getApplicationContext(),
                    "Error cargando la imagen",
                    Toast.LENGTH_SHORT)
                .show();
          }
          break;
      }

      if (pictureView != null && imageBitmap != null)
        //                pictureView.setImageDrawable(new BitmapDrawable(getResources(),
        // imageBitmap));
        pictureView.setImageDrawable(ImagesUtils.getRoundedBitmap(getResources(), imageBitmap));
    }
  }
  @Override
  public void onCreate(Bundle savedInstanceState) {
    super.onCreate(savedInstanceState);

    // mIsTwoPaneLayout = getResources().getBoolean(R.bool.has_two_panes);

    // Let this fragment contribute menu items
    // setHasOptionsMenu(true);

    try {
      chatSession = ((ChatSession) appSession);
      chatManager = chatSession.getModuleManager();
      // chatManager=moduleManager.getChatManager();
      errorManager = appSession.getErrorManager();
      toolbar = getToolbar();
      toolbar.setNavigationIcon(getResources().getDrawable(R.drawable.cht_ic_back_buttom));
    } catch (Exception e) {
      // CommonLogger.exception(TAG + "oncreate", e.getMessage(), e);
      if (errorManager != null)
        errorManager.reportUnexpectedSubAppException(
            SubApps.CHT_CHAT,
            UnexpectedSubAppExceptionSeverity.DISABLES_SOME_FUNCTIONALITY_WITHIN_THIS_FRAGMENT,
            e);
    }

    // Check if this fragment is part of a two-pane set up or a single pane by reading a
    // boolean from the application resource directories. This lets allows us to easily specify
    // which screen sizes should use a two-pane layout by setting this boolean in the
    // corresponding resource size-qualified directory.
    // mIsTwoPaneLayout = getResources().getBoolean(R.bool.has_two_panes);

    // Let this fragment contribute menu items
    // setHasOptionsMenu(true);

    // Create the main contacts adapter
    //        mAdapter = new ContactsAdapter(getActivity());
    //
    //        if (savedInstanceState != null) {
    //            // If we're restoring state after this fragment was recreated then
    //            // retrieve previous search term and previously selected search
    //            // result.
    //            mSearchTerm = savedInstanceState.getString(SearchManager.QUERY);
    //            mPreviouslySelectedSearchItem =
    //                    savedInstanceState.getInt(STATE_PREVIOUSLY_SELECTED_KEY, 0);
    //        }

    /*
     * An ImageLoader object loads and resizes an image in the background and binds it to the
     * QuickContactBadge in each item layout of the ListView. ImageLoader implements memory
     * caching for each image, which substantially improves refreshes of the ListView as the
     * user scrolls through it.
     *
     * To learn more about downloading images asynchronously and caching the results, read the
     * Android training class Displaying Bitmaps Efficiently.
     *
     * http://developer.android.com/training/displaying-bitmaps/
     */
    //        mImageLoader = new ImageLoader(getActivity(), getListPreferredItemHeight()) {
    //            @Override
    //            protected Bitmap processBitmap(Object data) {
    //                // This gets called in a background thread and passed the data from
    //                // ImageLoader.loadImage().
    //                return loadContactPhotoThumbnail((String) data, getImageSize());
    //            }
    //        };
    //
    //        // Set a placeholder loading image for the image loader
    //        mImageLoader.setLoadingImage(R.drawable.ic_contact_picture_holo_light);

    // Add a cache to the image loader
    // mImageLoader.addImageCache(getActivity().getSupportFragmentManager(), 0.1f);

  }
  @Override
  public View onCreateView(
      LayoutInflater inflater, ViewGroup container, Bundle savedInstanceState) {
    super.onCreate(savedInstanceState);
    View layout = inflater.inflate(R.layout.contact_edit_fragment, container, false);
    try {
      // Contact cont= chatSession.getSelectedContact();
      // TODO: metodo nuevo que lo buscara del module del actor
      // connections//chatManager.getChatUserIdentities();
      for (ChatActorCommunityInformation cont :
          chatManager.listAllConnectedChatActor(
              chatManager.newInstanceChatActorCommunitySelectableIdentity(
                  chatManager.getIdentityChatUsersFromCurrentDeviceUser().get(0)),
              2000,
              0)) {
        if (cont.getPublicKey() == chatSession.getData(ChatSession.CONTACT_DATA)) {
          contactname.add(cont.getAlias());
          contactid.add(cont.getPublicKey());
          contactalias.add(cont.getAlias());
          ByteArrayInputStream bytes = new ByteArrayInputStream(cont.getImage());
          BitmapDrawable bmd = new BitmapDrawable(bytes);
          contacticon.add(bmd.getBitmap());
          ContactAdapter adapter =
              new ContactAdapter(
                  getActivity(), contactname, contactalias, contactid, "edit", errorManager);
          // FermatTextView name =(FermatTextView)layout.findViewById(R.id.contact_name);
          // name.setText(contactname.get(0));
          // FermatTextView id =(FermatTextView)layout.findViewById(R.id.uuid);
          // id.setText(contactid.get(0).toString());

          // create bitmap from resource
          // Bitmap bm = BitmapFactory.decodeResource(getResources(), contacticon.get(0));

          // set circle bitmap
          ImageView mImage = (ImageView) layout.findViewById(R.id.contact_image);
          mImage.setImageBitmap(getCircleBitmap(contacticon.get(0)));
          break;
        }
      }
      aliasET = (EditText) layout.findViewById(R.id.aliasEdit);
      aliasET.setText(contactalias.get(0));
      saveBtn = (Button) layout.findViewById(R.id.saveContactButton);
      RelativeLayout contain = (RelativeLayout) layout.findViewById(R.id.containere);
    } catch (Exception e) {
      if (errorManager != null)
        errorManager.reportUnexpectedSubAppException(
            SubApps.CHT_CHAT,
            UnexpectedSubAppExceptionSeverity.DISABLES_SOME_FUNCTIONALITY_WITHIN_THIS_FRAGMENT,
            e);
    }

    toolbar.setNavigationOnClickListener(
        new View.OnClickListener() {
          @Override
          public void onClick(View v) {
            changeActivity(Activities.CHT_CHAT_OPEN_CHATLIST, appSession.getAppPublicKey());
          }
        });

    //        saveBtn.setOnClickListener(new View.OnClickListener() {
    //            @Override
    //            public void onClick(View v) {
    //                String aliasText = aliasET.getText().toString();
    //                if (TextUtils.isEmpty(aliasText)) {
    //                    return;
    //                }
    //                try {
    //                    for (ChatActorCommunityInformation cont:
    // chatManager.listAllConnectedChatActor(
    //                            (ChatActorCommunitySelectableIdentity) chatManager.
    //                                    getIdentityChatUsersFromCurrentDeviceUser().get(0), 2000,
    // 0)) {
    //                        if (cont.getPublicKey() ==
    // chatSession.getData(ChatSession.CONTACT_DATA)) {
    //                            cont.setAlias(aliasText);
    //                            //TODO:Cardozo revisar esta logica ya no aplica, esto viene de un
    // metodo nuevo que lo buscara del module del actor
    // connections//chatManager.getChatUserIdentities();
    //                            //chatManager.saveContact(con);
    //                            Toast.makeText(getActivity(), "Contact Updated",
    // Toast.LENGTH_SHORT).show();
    //                            //} catch (CantSaveContactException e) {
    //                            //
    // errorManager.reportUnexpectedSubAppException(SubApps.CHT_CHAT,
    // UnexpectedSubAppExceptionSeverity.DISABLES_SOME_FUNCTIONALITY_WITHIN_THIS_FRAGMENT, e);
    //
    //                        }
    //                    }
    //                }catch (Exception e){
    //                    if (errorManager != null)
    //                        errorManager.reportUnexpectedSubAppException(SubApps.CHT_CHAT,
    // UnexpectedSubAppExceptionSeverity.DISABLES_SOME_FUNCTIONALITY_WITHIN_THIS_FRAGMENT, e);
    //                }
    //            }
    //        });

    return layout;
    // loadDummyHistory();
    // Inflate the list fragment layout
    // return inflater.inflate(R.layout.contact_list_fragment, container, false);
  }
Exemple #24
0
  public void onCreate(Bundle savedInstanceState) {
    super.onCreate(savedInstanceState);

    contacts =
        new String[] {
          "Lucia Alarcon De Zamacona",
          "Juan Luis R. Pons",
          "Karina Rodríguez",
          "Simon Cushing",
          "Céline Begnis",
          "Taylor Backus",
          "Stephanie Himonidis",
          "Kimberly Brown"
        };
    amounts =
        new String[] {
          "$200.00", "$3,000.00", "$400.00", "$3.00", "$45.00", "$600.00", "50.00", "$80,000.00"
        };
    whens =
        new String[] {
          "4 hours ago",
          "5 hours ago",
          "yesterday 11:00 PM",
          "24 Mar 14",
          "3 Feb 14",
          "1 year ago",
          "1 year ago",
          "2 year ago"
        };
    notes =
        new String[] {
          "New telephone",
          "Old desk",
          "Car oil",
          "Sandwich",
          "Headphones",
          "Computer monitor",
          "Pen",
          "Apartment in Dubai"
        };
    totalAmount =
        new String[] {
          "$" + "17,485.00",
          "$" + "156,340.00",
          "$" + "422,545",
          "$" + "62,735.00",
          "$" + "45.00",
          "$" + "12,360.00",
          "$" + "75.00",
          "$" + "80,000"
        };
    historyCount =
        new String[] {
          "9 records",
          "19 records",
          "32 records",
          "11 records",
          "1 record",
          "11 records",
          "2 records",
          "1 record"
        };
    // pictures = new String[]{"luis_profile_picture", "guillermo_profile_picture",
    // "pedro_profile_picture", "mariana_profile_picture"};

    transactions =
        new String[][] {
          {"New telephone", "Hot dog", "Telephone credit", "Coffee"},
          {"Old desk", "Flat rent", "New glasses", "House in Europe", "Coffee", "Gum"},
          {"Car oil", "Headphgiones", "Apartment"},
          {"Sandwich", "New kitchen", "Camera repair"},
          {"Headphones"},
          {"Computer monitor", "New car"},
          {"Pen"},
          {"Apartment in Dubai"}
        };
    transactions_amounts =
        new String[][] {
          {"$200.00", "$3.00", "$460.00", "$2.00", "$1.5"},
          {"$3,000.00", "$34,200.00", "$4,500.00", "$4,000,000", "$2,00.00", "$0.50"},
          {"$400,00", "$43.00", "$350,000.00"},
          {"$3.00", "$55,000.00", "$7,500.00"},
          {"$45.00"},
          {"$600.00", "$5050.00"},
          {"$50.00"},
          {"$80,000.00"}
        };

    transactions_whens =
        new String[][] {
          {"4 hours ago", "8 hours ago", "yesterday 10:33 PM", "yesterday 9:33 PM"},
          {"5 hours ago", "yesterday", "20 Sep 14", "16 Sep 14", "13 Sep 14", "12 Sep 14"},
          {"yesterday 11:00 PM", "23 May 14", "12 May 14"},
          {"24 Mar 14", "15 Apr 14", "2 years ago"},
          {"3 Feb 14"},
          {"1 year ago", "1 year ago"},
          {"1 year ago"},
          {"2 years ago"}
        };
  }
 @Override
 public void onDestroy() {
   super.onDestroy();
 }
 @Override
 public void onCreateOptionsMenu(Menu menu, MenuInflater inflater) {
   super.onCreateOptionsMenu(menu, inflater);
   inflater.inflate(R.menu.dap_community_issuer_home_menu, menu);
 }
 @Override
 public void onViewCreated(View view, Bundle savedInstanceState) {
   super.onViewCreated(view, savedInstanceState);
 }
 @Override
 public void onCreateOptionsMenu(Menu menu, MenuInflater inflater) {
   super.onCreateOptionsMenu(menu, inflater);
   menu.clear();
 }
 @Override
 public void onCreateOptionsMenu(Menu menu, MenuInflater inflater) {
   super.onCreateOptionsMenu(menu, inflater);
   inflater.inflate(R.menu.dap_redeem_identity_menu_main, menu);
 }