Id
int64
21.6M
75.6M
PostTypeId
int64
1
1
AcceptedAnswerId
int64
21.6M
75.2M
ParentId
int64
Score
int64
-14
71
ViewCount
int64
5
87.5k
Body
stringlengths
1
26.6k
Title
stringlengths
20
150
ContentLicense
stringclasses
2 values
FavoriteCount
int64
0
0
CreationDate
stringlengths
23
23
LastActivityDate
stringlengths
23
23
LastEditDate
stringlengths
23
23
LastEditorUserId
int64
-1
21.3M
OwnerUserId
int64
127k
21.3M
Tags
sequencelengths
1
5
41,842,089
1
41,843,882
null
6
5,387
I've noticed that when OnElementPropertyChanged is fired on a VisualElement like a BoxView, the properties of the underlying platform view are not updated at that time. I want to know when the VisualElement's corresponding platform view is finished rendering, something like: `this.someBoxView.ViewHasRendered += (sender, e) => { // Here I would know underlying UIView (in iOS) has finished rendering };` Looking through some code inside of Xamarin.Forms, namely VisualElementRenderer.cs, it would seem that I could raise an event after OnPropertyChanged has finished. Something like: ``` protected virtual void OnElementPropertyChanged(object sender, PropertyChangedEventArgs e) { if (e.PropertyName == VisualElement.BackgroundColorProperty.PropertyName) SetBackgroundColor(Element.BackgroundColor); else if (e.PropertyName == Layout.IsClippedToBoundsProperty.PropertyName) UpdateClipToBounds(); else if (e.PropertyName == PlatformConfiguration.iOSSpecific.VisualElement.BlurEffectProperty.PropertyName) SetBlur((BlurEffectStyle)Element.GetValue(PlatformConfiguration.iOSSpecific.VisualElement.BlurEffectProperty)); // Raise event VisualElement visualElement = sender as VisualElement; visualElement.ViewHasRendered(); } ``` Naturally there's a few more complexities to adding an event to the VisualElement class, as it would need to be subclassed. But I think you can see what I'm after. While poking around I've noticed properties on VisualElement like IsInNativeLayout. But that only seems to be implementing in Win/WP8. Also, UpdateNativeWidget on VisualElementRenderer as well, however I can't figure out the proper way to leverage them. Any ideas? Much appreciated.
How can I know when a view is finished rendering?
CC BY-SA 3.0
0
2017-01-25T01:45:25.000
2019-03-25T14:33:02.487
null
null
203,099
[ "c#", "xamarin", "xamarin.forms", "mobile-development" ]
42,057,769
1
null
null
1
373
I'm trying to test my app on an iOS device using Xcode, however, when I go to create a personal team, this happens: [](https://i.stack.imgur.com/lLuDK.png) Xcode says I'm not on any development teams, even though it's supposed to automatically create one. I've already googled this problem, and already tried restarting both Xcode and the computer, removing the Apple ID, and adding it back in again, updating Xcode, even reinstalling it, but to no avail. Running Xcode 6.2 on an OSX 10.9.5 Thanks in advance!
Xcode 6.2–Cannot create free provisioning profile: "XXX" is not on any development teams
CC BY-SA 3.0
null
2017-02-05T21:52:53.807
2017-02-05T21:52:53.807
null
null
5,125,690
[ "ios", "xcode", "xcode6", "mobile-development" ]
42,139,148
1
42,139,454
null
2
5,564
I am trying to build the project but this is the error message that I am getting. ``` Error:(32, 13) Failed to resolve: com.firebase:firebase-jobdispatcher:0.5.0 Show in File Show in Project Structure dialog Error:Failed to resolve: com.android.databinding:compiler:2.2.3 Open File Show in Project Structure dialog ``` ``` apply plugin: 'com.android.application' android { compileSdkVersion 24 buildToolsVersion '24.0.0' defaultConfig { applicationId "com.example.android.sunshine" minSdkVersion 10 targetSdkVersion 24 versionCode 1 versionName "1.0" testInstrumentationRunner "android.support.test.runner.AndroidJUnitRunner" } buildTypes { release { minifyEnabled false } } dataBinding.enabled = true } dependencies { compile fileTree(include: ['*.jar'], dir: 'libs') compile 'com.android.support:appcompat-v7:24.2.1' compile 'com.android.support:recyclerview-v7:24.2.1' compile 'com.android.support:preference-v7:24.2.1' compile 'com.android.support.constraint:constraint-layout:1.0.0-beta3' compile 'com.firebase:firebase-jobdispatcher:0.5.0' // Instrumentation dependencies use androidTestCompile // (as opposed to testCompile for local unit tests run in the JVM) androidTestCompile 'junit:junit:4.12' androidTestCompile 'com.android.support:support-annotations:24.2.1' androidTestCompile 'com.android.support.test:runner:0.5' androidTestCompile 'com.android.support.test:rules:0.5' } ``` ``` buildscript { repositories { jcenter() } dependencies { classpath 'com.android.tools.build:gradle:2.2.3' // NOTE: Do not place your application dependencies here; they belong // in the individual module build.gradle files } } allprojects { String osName = System.getProperty("os.name").toLowerCase(); if (osName.contains("windows")) { buildDir = "C:/tmp/${rootProject.name}/${project.name}" } repositories { jcenter() } } task clean(type: Delete) { delete rootProject.buildDir } ``` ``` <?xml version="1.0" encoding="utf-8"?> <!-- Copyright (C) 2016 The Android Open Source Project Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except in compliance with the License. You may obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 Unless required by applicable law or agreed to in writing, software distributed under the License is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the License for the specific language governing permissions and limitations under the License.--> <manifest xmlns:android="http://schemas.android.com/apk/res/android" package="com.example.android.sunshine"> <!-- This permission is necessary in order for Sunshine to perform network access. --> <uses-permission android:name="android.permission.INTERNET"/> <application android:allowBackup="true" android:icon="@mipmap/ic_launcher" android:label="@string/app_name" android:supportsRtl="true" android:theme="@style/AppTheme"> <!--The manifest entry for our MainActivity. Each Activity requires a manifest entry--> <activity android:name=".MainActivity" android:label="@string/app_name" android:launchMode="singleTop" android:theme="@style/AppTheme.Forecast"> <intent-filter> <action android:name="android.intent.action.MAIN"/> <category android:name="android.intent.category.LAUNCHER"/> </intent-filter> </activity> <!--The manifest entry for our DetailActivity. Each Activity requires a manifest entry--> <activity android:name=".DetailActivity" android:label="@string/title_activity_detail" android:parentActivityName=".MainActivity" android:theme="@style/AppTheme"> <meta-data android:name="android.support.PARENT_ACTIVITY" android:value=".MainActivity"/> </activity> <!--The manifest entry for our SettingsActivity. Each Activity requires a manifest entry--> <activity android:name=".SettingsActivity"/> <!-- Our ContentProvider --> <provider android:name=".data.WeatherProvider" android:authorities="@string/content_authority" android:exported="false"/> <!--This is required for immediate syncs --> <service android:name=".sync.SunshineSyncIntentService" android:exported="false" /> <!-- This is the Service declaration used in conjunction with FirebaseJobDispatcher --> <service android:name=".sync.SunshineFirebaseJobService" android:exported="false"> <intent-filter> <action android:name="com.firebase.jobdispatcher.ACTION_EXECUTE"/> </intent-filter> </service> </application> </manifest> ``` How can I resolve this? I am getting no resources on the internet also.
Failed to resolve: com.firebase:firebase-jobdispatcher:0.5.0
CC BY-SA 3.0
0
2017-02-09T14:21:39.657
2018-09-07T01:22:52.887
null
null
3,841,509
[ "android", "firebase", "firebase-realtime-database", "firebase-storage", "mobile-development" ]
42,200,831
1
42,200,876
null
71
87,548
I can't find this information. Is it true that Android React Native runs on sdkMin18 and therefore makes it supported by most android versions?
Which version does React Native support (iOS and Android)?
CC BY-SA 3.0
0
2017-02-13T09:36:25.900
2021-12-17T09:50:12.453
2017-11-20T08:29:20.990
3,527,343
7,490,462
[ "android", "ios", "react-native", "mobile-application", "mobile-development" ]
42,313,478
1
null
null
2
1,824
My Android application helps users to follow their daily plan by sending notifications at a specific time. This task is easy to solve with JobScheduler. It seems easy, light and up to date solution. What I'm struggling with is how to plan all notifications every day. I need to run code that checks user daily plan and schedules notification every day at midnight silently. And so far I found 2 approaches It can be re-scheduled with > public final void jobFinished(JobParameters params, boolean needsReschedule) but I think it's a bad solution because 1. I'll need to treat finished job as failed, although it's successful 2. Schedule time will increase linearly/exponentially and that is not acceptable for me. , but it also has a couple of drawbacks 1. According to documentation > Registered alarms are retained while the device is asleep (and can optionally wake the device up if they go off during that time), but will be cleared if it is turned off and rebooted. And this is not acceptable, as my users can miss something important. 1. I've read that it kills battery pretty quickly. Is that true? that I've found in documentation doesn't looks like what I need. ([https://developer.android.com/topic/performance/scheduling.html](https://developer.android.com/topic/performance/scheduling.html)) Any ideas how run scheduled task on a daily basis that will be light and resilient to reboot?
Run scheduled task once a day on Android
CC BY-SA 3.0
null
2017-02-18T09:35:27.507
2017-02-18T18:11:13.497
null
null
3,087,024
[ "android", "android-alarms", "mobile-development", "android-jobscheduler" ]
42,386,684
1
null
null
1
1,121
Currently I'm trying to get the input choice from List Preference which has (Italic, Bold, Underlined) styles in it, but I am not quite sure how to accomplished this specifically. In the past, I've successfully done it for font type, size and colors. Font Type Example: ``` SharedPreferences sharedPreferences = PreferenceManager.getDefaultSharedPreferences(getApplicationContext()); String s = sharedPreferences.getString("font_list", "gnuolane rg.ttf"); Typeface face = Typeface.createFromAsset(getAssets(), "fonts/" + s); editText.setTypeface(face); ``` Font Size Example: ``` String s2 = sharedPreferences.getString("font_size", "8"); editText.setTextSize(Float.parseFloat(s2)) ``` How can I achieve the same idea but with font styles, such as Bold, Italic, Underlined?
Android Studio Shared Preferences Set Font Style
CC BY-SA 3.0
0
2017-02-22T08:52:09.510
2017-02-23T00:16:27.053
null
null
7,439,370
[ "android", "android-studio", "fonts", "mobile-development" ]
42,597,248
1
42,597,311
null
0
58
I am new to android development, I am making an app which has a pop up window which would display a webpage in it. I have started working on it but I cant figure how to proceed. Following are the codes I used, so far completely errorless. || activity_main.xml ``` <?xml version="1.0" encoding="utf-8"?> <LinearLayout xmlns:android="http://schemas.android.com/apk/res/android" android:layout_width="fill_parent" android:layout_height="fill_parent" android:orientation="vertical" android:weightSum="1" android:background="@color/aquamarine"> <TextView android:layout_width="wrap_content" android:layout_height="wrap_content" android:textAppearance="?android:attr/textAppearanceMedium" android:text="TEST APPLICATION" android:id="@+id/textView" android:layout_gravity="center_horizontal" android:layout_weight="0.07" /> </LinearLayout> ``` || MainActivity.java ``` package com.example.android.two; import android.app.Dialog; import android.support.v7.app.AppCompatActivity; import android.os.Bundle; import android.view.View; import android.webkit.WebSettings; import android.webkit.WebView; import android.widget.Button; import android.widget.EditText; import com.example.android.two.R; public class MainActivity extends AppCompatActivity { @Override protected void onCreate(Bundle savedInstanceState) { super.onCreate(savedInstanceState); setContentView(R.layout.activity_main); final Dialog dialog = new Dialog(this); dialog.setContentView(R.layout.pop); WebView wv = (WebView)dialog.findViewById(R.id.wv); WebSettings webSettings = wv.getSettings(); wv.loadUrl("http://www.google.com"); webSettings.setJavaScriptEnabled(true); dialog.show(); Button btnDismiss = (Button)dialog.findViewById(R.id.dismiss); btnDismiss.setOnClickListener(new Button.OnClickListener(){ @Override public void onClick(View v) { // TODO Auto-generated method stub dialog.dismiss(); }}); } } ``` || pop.xml ``` <?xml version="1.0" encoding="utf-8"?> <RelativeLayout xmlns:android="http://schemas.android.com/apk/res/android" android:layout_width="fill_parent" android:layout_height="fill_parent" android:orientation="vertical" android:background="@android:color/background_light" android:weightSum="1"> <RelativeLayout android:layout_width="380dp" android:layout_height="380dp" android:layout_centerVertical="true" android:layout_centerHorizontal="true" android:layout_margin="1dp" android:background="@android:color/darker_gray"> <WebView android:layout_width="380dp" android:layout_height="380dp" android:id="@+id/wv" android:layout_alignParentTop="true" android:layout_alignParentStart="true" /> <Button android:id="@+id/dismiss" android:layout_width="40dp" android:layout_height="40dp" android:text="X" android:layout_alignTop="@+id/wv" android:layout_alignParentStart="true" /> </RelativeLayout> </RelativeLayout> ```
a pop up window which would display a webpage in it
CC BY-SA 3.0
null
2017-03-04T14:40:26.730
2017-03-04T14:58:54.290
null
null
5,832,648
[ "android", "android-studio", "mobile-development" ]
42,684,654
1
null
null
2
634
Basically I'm asking is if I was to download eclipse right now(8/3/17), would I still be able to get all the required plugins to effectively develop android applications. if so can some one tell me where I could get them.? Everyone keeps sending me to the android studio page but I can't find a link to the stand alone sdk without downloading android studio Any help will be appreciated
Does eclipse still work for android development.?
CC BY-SA 3.0
null
2017-03-09T00:44:36.060
2018-04-20T07:37:41.293
2018-04-20T07:37:41.293
null
7,656,247
[ "eclipse", "development-environment", "mobile-development" ]
42,689,775
1
42,736,959
null
70
17,322
Why I didn't see Auto-Renewable Subscription in iTunes Connect -> In-App Purchases -> Select the In-App Purchase you want to create. I see only Consumable, Non-Consumable, Non-Renewing Subscription [](https://i.stack.imgur.com/FUbRQ.png)
Why I didn't see Auto-Renewable Subscription in iTunes Connect
CC BY-SA 3.0
0
2017-03-09T08:02:01.777
2022-11-22T16:01:11.077
null
null
5,964,898
[ "ios", "app-store-connect", "subscription", "mobile-development" ]
42,748,250
1
null
null
0
54
I am currently trying to install PhoneGap (Cordova) onto my computer. I thought I was out of the woods when all of a sudden this popped up (I included the command I typed in). ``` ~$ sudo apt-get install lib32z1 lib32ncurses5 lib32bz2-1.0 lib32stdc++6 Reading package lists... Done Building dependency tree Reading state information... Done E: Unable to locate package lib32bz2-1.0 E: Couldn't find any package by glob 'lib32bz2-1.0' E: Couldn't find any package by regex 'lib32bz2-1.0' ``` Hopefully you guys can help me out here. -Thank you for your time.
How could I fix this error when downloading PhoneGap (file could not be found)
CC BY-SA 3.0
null
2017-03-12T13:54:09.153
2017-03-14T06:59:06.190
null
null
7,559,946
[ "cordova", "mobile-development" ]
42,792,889
1
42,794,012
null
1
102
I make a Google Auth for my App, but I don't know how to present a new viewController after touchup GIDSignInButton! Here how I make GIDSignInButton: `viewDidLoad (){ let googleBtn = GIDSignInButton() googleBtn.frame = CGRect(x: 16, y: 500 + 66, width: view.frame.width - 32, height: 35) view.addSubview(googleBtn)}`
Present viewController after touchUp GIDSignInButton()!
CC BY-SA 3.0
0
2017-03-14T17:37:26.663
2017-03-14T18:39:42.430
null
null
7,710,422
[ "swift", "xcode", "mobile-development" ]
42,883,654
1
null
null
0
32
I'm new to coding mobile applications. May I just ask if you have any on how can I `share` on in just a `single upload click`? Let's say I want my `current snaps/uploads` on to be on also and vice-versa. I'm thinking of running it on the background (?) Or it could be like the tool `Selenium Web`but for this case, it is between mobile applications.
Uploading images/files on multiple platforms at once
CC BY-SA 3.0
null
2017-03-19T06:37:34.820
2017-03-19T06:41:44.100
null
null
5,227,867
[ "android", "android-studio", "mobile", "mobile-devices", "mobile-development" ]
42,905,200
1
43,985,655
null
3
980
When trying to view an xml using the "design" tab, the leftmost 200 pixels or so of the preview are being cut off, and I can't get Android Studio to show the full picture no matter what I do. Here's what I'm seeing: [http://imgur.com/a/3aeVz](https://imgur.com/a/3aeVz) And a gif of the problem: [https://gfycat.com/PersonalDetailedBallpython](https://gfycat.com/PersonalDetailedBallpython) Unfortunately the gif was too long, and cuts out some of my trying things out. Closing the project pane does nothing, and while zoomed in, the pan and zoom detail will tell me I'm seeing the upper left corner, when in reality the leftmost 200 pixels are cut off. Does anyone have any info that would help? Thanks!
Android Studio Design View is cut off
CC BY-SA 3.0
null
2017-03-20T13:43:59.377
2017-05-15T17:38:51.693
null
null
7,740,177
[ "android", "android-studio", "mobile-development" ]
42,950,616
1
null
null
1
668
I'm trying to create an app with navigation drawer and swipe tabs, I want that my swipe tab be always visible like the toolbar. My problem is that the fragment of the swipe bar and the navigation drawer are overlapping. [the image of my app](https://i.stack.imgur.com/0XKUM.png) Could anyone help me please .Here is some peace of my code: MainActivity ``` @Override protected void onCreate(Bundle savedInstanceState) { super.onCreate(savedInstanceState); setContentView(R.layout.activity_main); toolbar = (Toolbar) findViewById(R.id.toolbar); setSupportActionBar(toolbar); //============= viewPager = (ViewPager) findViewById(R.id.viewpager); setupViewPager(viewPager); //============= tabLayout = (TabLayout) findViewById(R.id.tabs); tabLayout.setupWithViewPager(viewPager); //============= mHandler = new Handler(); drawer = (DrawerLayout) findViewById(R.id.drawer_layout); navigationView = (NavigationView) findViewById(R.id.nav_view); fab = (FloatingActionButton) findViewById(R.id.fab); setUpNavigationView(); } /*** * Swipe Tabs */ private void setupViewPager(ViewPager viewPager) { ViewPagerAdapter adapter = new ViewPagerAdapter(getSupportFragmentManager()); adapter.addFragment(new HomeFragment(), "ONE"); adapter.addFragment(new AgendaFragment(), "TWO"); adapter.addFragment(new NotificationFragment(), "THREE"); viewPager.setAdapter(adapter); } class ViewPagerAdapter extends FragmentPagerAdapter { private final List<Fragment> mFragmentList = new ArrayList<>(); private final List<String> mFragmentTitleList = new ArrayList<>(); public ViewPagerAdapter(FragmentManager manager) { super(manager); } @Override public Fragment getItem(int position) { return mFragmentList.get(position); } @Override public int getCount() { return mFragmentList.size(); } public void addFragment(Fragment fragment, String title) { mFragmentList.add(fragment); mFragmentTitleList.add(title); } @Override public CharSequence getPageTitle(int position) { return mFragmentTitleList.get(position); } } /*** * Returns respected fragment that user * selected from navigation menu */ private void loadHomeFragment() { // selecting appropriate nav menu item selectNavMenu(); // if user select the current navigation menu again, don't do anything // just close the navigation drawer if (getSupportFragmentManager().findFragmentByTag(CURRENT_TAG) != null) { drawer.closeDrawers(); // show or hide the fab button toggleFab(); return; } Runnable mPendingRunnable = new Runnable() { @Override public void run() { // update the main content by replacing fragments Fragment fragment = getHomeFragment(); if(fragment != null){ FragmentTransaction fragmentTransaction = getSupportFragmentManager().beginTransaction(); fragmentTransaction.setCustomAnimations(android.R.anim.fade_in, android.R.anim.fade_out); fragmentTransaction.replace(R.id.frame, fragment, CURRENT_TAG); fragmentTransaction.commitAllowingStateLoss();} } }; // If mPendingRunnable is not null, then add to the message queue if (mPendingRunnable != null) { mHandler.post(mPendingRunnable); } // show or hide the fab button toggleFab(); //Closing drawer on item click drawer.closeDrawers(); // refresh toolbar menu invalidateOptionsMenu(); } private Fragment getHomeFragment() { switch (navItemIndex) { case 0: // item1 ItemoneFragment itemoneFragment= new ItemoneFragment(); return my_selectionFragment; case 1: // item2 ItemtowFragment itemtowFragment = new ItemtowFragment(); return my_activitiesFragment; case 2: // item3 ItemthreeFragment itemthreeFragment = new ItemthreeFragment(); return groupFragment; default: return null; } } private void selectNavMenu() { navigationView.getMenu().getItem(navItemIndex).setChecked(true); } private void setUpNavigationView() { //Setting Navigation View Item Selected Listener to handle the item click of the navigation menu navigationView.setNavigationItemSelectedListener(new NavigationView.OnNavigationItemSelectedListener() { // This method will trigger on item Click of navigation menu @Override public boolean onNavigationItemSelected(MenuItem menuItem) { //Check to see which item was being clicked and perform appropriate action switch (menuItem.getItemId()) { //Replacing the main content with ContentFragment Which is our Inbox View; case R.id.nav_my_activities: navItemIndex = 0; CURRENT_TAG = TAG_HOME; break; case R.id.nav_my_selection: navItemIndex = 1; CURRENT_TAG = TAG_PHOTOS; break; case R.id.nav_group: navItemIndex = 2; CURRENT_TAG = TAG_GROUPS; break; default: navItemIndex = 0; } //Checking if the item is in checked state or not, if not make it in checked state if (menuItem.isChecked()) { menuItem.setChecked(false); } else { menuItem.setChecked(true); } menuItem.setChecked(true); loadHomeFragment(); return true; } }); ActionBarDrawerToggle actionBarDrawerToggle = new ActionBarDrawerToggle(this, drawer, toolbar, R.string.openDrawer, R.string.closeDrawer) { @Override public void onDrawerClosed(View drawerView) { // Code here will be triggered once the drawer closes as we dont want anything to happen so we leave this blank super.onDrawerClosed(drawerView); } @Override public void onDrawerOpened(View drawerView) { // Code here will be triggered once the drawer open as we dont want anything to happen so we leave this blank super.onDrawerOpened(drawerView); } }; //Setting the actionbarToggle to drawer layout drawer.setDrawerListener(actionBarDrawerToggle); //calling sync state is necessary or else your hamburger icon wont show up actionBarDrawerToggle.syncState(); } ``` activity_main.xml ``` <android.support.v4.widget.DrawerLayout xmlns:android="http://schemas.android.com/apk/res/android" xmlns:app="http://schemas.android.com/apk/res-auto" xmlns:tools="http://schemas.android.com/tools" android:id="@+id/drawer_layout" android:layout_width="match_parent" android:layout_height="match_parent" android:fitsSystemWindows="true" tools:openDrawer="start"> <include layout="@layout/app_bar_main" android:layout_width="match_parent" android:layout_height="match_parent" /> <android.support.design.widget.NavigationView android:id="@+id/nav_view" android:layout_width="wrap_content" android:layout_height="match_parent" android:layout_gravity="start" android:fitsSystemWindows="true" app:headerLayout="@layout/nav_header_main" app:menu="@menu/activity_main_drawer" /> </android.support.v4.widget.DrawerLayout> ``` app_bar_main.xml ``` <?xml version="1.0" encoding="utf-8"?> <android.support.design.widget.CoordinatorLayout xmlns:android="http://schemas.android.com/apk/res/android" xmlns:app="http://schemas.android.com/apk/res-auto" xmlns:tools="http://schemas.android.com/tools" android:layout_width="match_parent" android:layout_height="match_parent" android:fitsSystemWindows="true" tools:context="com.myApp.activities.MainActivity"> <android.support.design.widget.AppBarLayout android:layout_width="match_parent" android:layout_height="wrap_content" android:theme="@style/AppTheme.AppBarOverlay"> <android.support.v7.widget.Toolbar android:id="@+id/toolbar" android:layout_width="match_parent" android:layout_height="?attr/actionBarSize" android:background="?attr/colorPrimary" app:popupTheme="@style/AppTheme.PopupOverlay" /> <android.support.design.widget.TabLayout android:id="@+id/tabs" android:layout_width="match_parent" android:layout_height="wrap_content" app:tabMode="fixed" app:tabGravity="fill"/> </android.support.design.widget.AppBarLayout> <android.support.v4.view.ViewPager android:id="@+id/viewpager" android:layout_width="match_parent" android:layout_height="match_parent" app:layout_behavior="@string/appbar_scrolling_view_behavior" /> <FrameLayout android:id="@+id/frame" android:layout_width="match_parent" android:layout_height="match_parent" app:layout_behavior="@string/appbar_scrolling_view_behavior"></FrameLayout> <android.support.design.widget.FloatingActionButton android:id="@+id/fab" android:layout_width="wrap_content" android:layout_height="wrap_content" android:layout_gravity="bottom|end" android:layout_margin="@dimen/fab_margin" app:backgroundTint="@color/colorPrimary" app:srcCompat="@android:drawable/ic_dialog_email" /> </android.support.design.widget.CoordinatorLayout> ```
Why the fragment of the swipe tabs overlaps with navigation drawer fragments?
CC BY-SA 3.0
null
2017-03-22T11:40:45.023
2017-03-22T12:57:14.807
2017-03-22T12:48:05.113
6,241,193
6,241,193
[ "android", "android-tabs", "navigation-drawer", "mobile-development" ]
43,082,291
1
null
null
0
316
I'm trying to create a database to store data entered on the journal app I'm developing at the moment, but I came across an small issue where I try to see if the database is created, but it doesn't show when I look on Android Device Monitor > data > data > database folders. What exactly am I missing on my code? ``` public class DBOpenHelper extends SQLiteOpenHelper{ //Constants for db name and version private static final String DATABASE_NAME = "notes.db"; private static final int DATABASE_VERSION = 1; //Constants for identifying table and columns public static final String TABLE_NOTES = "notes"; public static final String NOTE_ID = "_id"; public static final String NOTE_TEXT = "noteText"; public static final String NOTE_CREATED = "noteCreated"; //SQL to create table private static final String TABLE_CREATE = "CREATE TABLE " + TABLE_NOTES + " (" + NOTE_ID + " INTEGER PRIMARY KEY AUTOINCREMENT, " + NOTE_TEXT + " TEXT, " + NOTE_CREATED + " TEXT default CURRENT_TIMESTAMP" + ")"; public DBOpenHelper(Context context) { super(context, DATABASE_NAME, null, DATABASE_VERSION); } @Override public void onCreate(SQLiteDatabase db) { db.execSQL(TABLE_CREATE); } @Override public void onUpgrade(SQLiteDatabase db, int oldVersion, int newVersion) { db.execSQL("DROP TABLE IF EXISTS " + TABLE_NOTES); onCreate(db); } } ``` --- ``` public class HomeActivity extends AppCompatActivity implements NavigationView.OnNavigationItemSelectedListener { @Override protected void onCreate(Bundle savedInstanceState) { super.onCreate(savedInstanceState); setContentView(R.layout.activity_home); DBOpenHelper helper = new DBOpenHelper(this); SQLiteDatabase database = helper.getWritableDatabase(); } ```
Android Studio SQLite Database Unable to find on Android Device Monitor
CC BY-SA 3.0
null
2017-03-29T00:37:57.913
2017-03-29T00:37:57.913
null
null
7,439,370
[ "java", "android", "sqlite", "android-studio", "mobile-development" ]
43,087,321
1
null
null
0
1,245
first of all thank for your time. I have a jar library which would be included as library in my Android Application. This jar, among other things, is able to get the RGB values from a jpg image. This works perfectly in my java application but when I runs it in my Android application it does not work because the class `ImageIO.read(File file)` (Bufferedimage) does not implemented in Android. I read something about using Bitmap class but i do not find out anything about it. Could you help me with this method you find here below? ``` public static int[][][] getImageRgb(BufferedImage image) { int width = image.getWidth(); int height = image.getHeight(); int[][][] rgb = new int[height][width][3]; for (int i = 0; i < height; i++) { for (int j = 0; j < width; j++) { int pixel = image.getRGB(j, i); rgb[i][j] = getPixelRgb(pixel); } } return rgb; } ``` Where getPixelRgb is a function aims this: ``` public static int[] getPixelRgb(int pixel) { // int alpha = (pixel >> 24) & 0xff; int red = (pixel >> 16) & 0xff; int green = (pixel >> 8) & 0xff; int blue = (pixel) & 0xff; return new int[]{red, green, blue}; } ``` I really I do not know how to transform this methods for Android. I look forward to hearing from you. Thank a lot.
Get RGB of JPG in Android
CC BY-SA 3.0
null
2017-03-29T07:41:47.620
2017-03-29T07:58:12.160
null
null
2,215,187
[ "java", "android", "bufferedimage", "javax.imageio", "mobile-development" ]
43,148,075
1
43,148,182
null
0
24
i tried Flags like ``` intent.setFlags(Intent.FLAG_ACTIVITY_NEW_TASK |Intent.FLAG_ACTIVITY_CLEAR_TASK); ``` i Login to my application and open the home page > when i receive a notification and preessed on it to see details at home page it opened well But the previous
i am Trying more Flags to prevent the Activity to be opened more than one time at the Same time
CC BY-SA 3.0
0
2017-03-31T19:13:15.103
2017-03-31T19:20:10.893
null
null
7,686,677
[ "android", "android-intent", "android-activity", "android-pendingintent", "mobile-development" ]
43,168,028
1
null
null
-2
17
When a costumer buys something from a website how does the owner know where to send the items purchased and is there a way to get notification to my phone when a purchase is made from my website
how do i know where to send item bought on my websites
CC BY-SA 3.0
null
2017-04-02T11:55:39.780
2017-04-02T12:11:10.630
null
null
7,804,466
[ "e-commerce", "web-development-server", "mobile-development" ]
43,180,963
1
null
null
1
421
In my UWP application now I store some value in the `ApplicationData.Current.LocalSettings` and when I uninstall the app all the values will be lost. I need to know do we have any place to store the value which will be save and can be accessed even after I reinstall the app in the device? I need similar like what we do it in Windows application (WPF) read/write with system registry and I understand that we can do it UWP applications.
UWP data persistence after uninstall the app
CC BY-SA 4.0
null
2017-04-03T09:25:07.703
2022-07-30T09:12:55.187
2022-07-30T09:12:55.187
472,495
444,158
[ ".net", "wpf", "uwp", "mobile-development" ]
43,382,996
1
null
null
1
554
Using UWP I am creating a file in the Documents folder and after creation I am trying to hide the file but the file was not getting hidden. Below is the sample code I used to hide. ``` var localsetting = KnownFolders.DocumentsLibrary; var versionfile = await localsetting.CreateFileAsync("TEST.txt", CreationCollisionOption.OpenIfExists); await FileIO.WriteTextAsync(versionfile, "TEst Content2"); System.IO.File.SetAttributes(versionfile.Path, System.IO.FileAttributes.Hidden); ``` Is it possible to hide the file?
Hide created file in UWP
CC BY-SA 4.0
null
2017-04-13T03:21:23.077
2022-07-30T09:12:24.880
2022-07-30T09:12:24.880
472,495
444,158
[ "c#", ".net", "xaml", "uwp", "mobile-development" ]
43,393,322
1
43,393,654
null
3
4,382
Based on the following article [https://developer.apple.com/ios/human-interface-guidelines/graphics/launch-screen/](https://developer.apple.com/ios/human-interface-guidelines/graphics/launch-screen/) having a launch screen aka splash screen is a must for ios app when developing. but I realised many apps such as facebook or twiter does not have any launch screen on iPhone. I have tried removing the LaunchScreen.xib from my project on XCode (8) but I get build fail error. Is there any way to get rid of it?
Is iOS app Launch Screen (splash screen) a must?
CC BY-SA 3.0
0
2017-04-13T13:13:08.713
2017-05-24T04:38:01.890
null
null
1,427,257
[ "ios", "xcode", "react-native", "mobile-application", "mobile-development" ]
43,397,701
1
null
null
0
73
I've been trying to call an Async method from another class, but the application seems to be constantly crashing when I do so. The Async method works when I call it from within the class. I believe I've narrowed it down to when it tries to display the message on the UI thread (toast/message box). However, every solution I've tried hasn't succeeded. Below you can see my two classes. Any help will be much-appreciated thanks. MainActivity.java ``` public class MainActivity extends AppCompatActivity { private Button mBtLaunchActivity; private ListView listView1; @Override public void onCreate(Bundle savedInstanceState) { super.onCreate(savedInstanceState); setContentView(R.layout.activity_main); VideoList videoList_data[] = new VideoList[] { //new VideoList(R.drawable.weather_cloudy, "Cloudy"), new VideoList(R.drawable.air_squat_icon, "Air Squat Tutorial"), new VideoList(R.drawable.deadlift_icon, "Deadlift Tutorial"), new VideoList(R.drawable.front_squat_icon, "Front Squat Tutorial"), new VideoList(R.drawable.bicep_curl_icon, "Bicep Curl Tutorial") }; VideoListAdapter adapter = new VideoListAdapter(this, R.layout.listview_item_row, videoList_data); listView1 = (ListView) findViewById(R.id.listView1); /*View header = (View) getLayoutInflater().inflate(R.layout.listview_header_row, null); listView1.addHeaderView(header);*/ listView1.setAdapter(adapter); //textView userText = (textView) findViewById(R.id.txtTitle); //final String user = userText toString(); listView1.setOnItemClickListener(new AdapterView.OnItemClickListener() { @Override public void onItemClick(AdapterView<?> adapterView, View view, int position, long id) { switch (position){ case 0: System.out.println("omxplayer air_squat.mp4"); sendCommand("ls"); break; case 1: System.out.println("omxplayer deadlift.mp4"); break; case 2: System.out.println("omxplayer front_squat.mp4"); break; case 3: System.out.println("omxplayer bicep_curl.mp4"); break; } //Intent intent = new Intent(MainActivity.this, SSHConnectionDetails.class); //Bundle bundle = new Bundle(); //bundle.putString("vidoedetails", filedetails); //bundle.putString("videoname", filename); //intent.putExtras(bundle); //intent.putExtra("videofilename", filename); //intent.putExtra("vidoefiledetails", filedetails); //startActivity(intent); //System.out.println("Clicked pos " + position); // your code is here on item click //System.out.println("Clicked id " + id); //System.out.println(position); } }); } private void sendCommand(String cmd){ //String sshCommand = command; //SSHConnectionDetails scd = new SSHConnectionDetails(); //scd.host = ""; //SharedPreferences sharedPref = getPreferences(Context.MODE_PRIVATE); //SharedPreferences sharedPref = getApplicationContext().getSharedPreferences("MyPref", 0); //String defaultValue = "Nothing"; //System.out.println(getString(R.string.username)); //String highScore = sharedPref.getString(getString(R.string.username), defaultValue); //String host = sharedPref.getString("host", ""); //String user = sharedPref.getString("username", ""); //String pass = sharedPref.getString("password", ""); //int port = sharedPref.getInt("port", 22); //Sending over the connection details & command to be executed System.out.println("AT SEND COMMAND 1"); SSHConnectionDetails scd = new SSHConnectionDetails(); scd.sendCommand("host","user","pass",22,cmd); //Send host,user,pass,port,command to be executed in a method //Toast.makeText(getApplicationContext(), host + user + pass + port, Toast.LENGTH_SHORT).show(); } private void launchActivity() { //launching the SSHConnectionDetails activity Intent intent = new Intent(this, SSHConnectionDetails.class); startActivity(intent); } @Override public boolean onCreateOptionsMenu(Menu menu) { // Inflate the menu; this adds items to the action bar if it is present. getMenuInflater().inflate(R.menu.menu_main, menu); return true; } @Override public boolean onOptionsItemSelected(MenuItem item) { // Handle action bar item clicks here. The action bar will // automatically handle clicks on the Home/Up button, so long // as you specify a parent activity in AndroidManifest.xml. int id = item.getItemId(); //noinspection SimplifiableIfStatement if (id == R.id.SSH) { launchActivity(); //return true; } return super.onOptionsItemSelected(item); } ``` } SSHConnectionDetails.java ``` public class SSHConnectionDetails extends AppCompatActivity { private String host; private String user; private String pass; private int port; @Override protected void onCreate(Bundle savedInstanceState) { super.onCreate(savedInstanceState); setContentView(R.layout.activity_sshconnection_details); SharedPreferences sharedPref = getApplicationContext().getSharedPreferences("MyPref", 0); String host = sharedPref.getString("host", ""); String user = sharedPref.getString("username", ""); String pass = sharedPref.getString("password", ""); int port = sharedPref.getInt("port", 22); EditText hostText = (EditText)findViewById(R.id.Host); EditText userText = (EditText)findViewById(R.id.User); EditText passText = (EditText)findViewById(R.id.Pass); EditText portText = (EditText)findViewById(R.id.Port); hostText.setText(host, TextView.BufferType.EDITABLE); userText.setText(user, TextView.BufferType.EDITABLE); passText.setText(pass, TextView.BufferType.EDITABLE); portText.setText(String.valueOf(port), TextView.BufferType.EDITABLE); getSupportActionBar().setDisplayHomeAsUpEnabled(true); Toast.makeText(getApplicationContext(),host, Toast.LENGTH_SHORT).show(); } public boolean onOptionsItemSelected(MenuItem item) { switch (item.getItemId()) { // Respond to the action bar's Up/Home button case android.R.id.home: NavUtils.navigateUpFromSameTask(this); return true; } return super.onOptionsItemSelected(item); } public void navigateUp(View view){ NavUtils.navigateUpFromSameTask(this); } public void testInput2(View view){ //Collecting the inputted connection details and assigning them to variables EditText userText = (EditText) findViewById(R.id.User); user = userText.getText().toString(); System.out.println(user); EditText passText = (EditText) findViewById(R.id.Pass); pass = passText.getText().toString(); System.out.println(pass); EditText hostText = (EditText) findViewById(R.id.Host); host = hostText.getText().toString(); System.out.println(host); EditText portText = (EditText) findViewById(R.id.Port); port = Integer.parseInt(portText.getText().toString()); System.out.println(port); sendCommand(host,user,pass,port,"ls"); } public void sendCommand(final String hst, final String uname, final String pword, final int prt, final String cmd){ System.out.println("AT SEND COMMAND 2"); ExecuteSSHConnectionTask esct = new ExecuteSSHConnectionTask(SSHConnectionDetails.this); esct.execute(); } ``` } ExecuteSSHConnectionTask.Java ``` public class ExecuteSSHConnectionTask extends AsyncTask<Integer, Void, String>{ private Context mContext; String uname = "user"; String pword = "pass"; int prt = 22; String hst = "host"; String cmd = "ls"; public ExecuteSSHConnectionTask(Context context){ mContext = context; } ExecuteRemoteCommand erc = new ExecuteRemoteCommand(mContext); protected String doInBackground(Integer... params) { try { erc.executeRemoteCommand(uname, pword, hst, prt, cmd); } catch (Exception e) { //displayMessage("Connection Unsuccessful: " + e.toString()); e.printStackTrace(); } return "Test"; } protected void onPostExecute(String result) { //Toast.makeText(mContext, "Test" + result, Toast.LENGTH_SHORT).show(); //finish(); erc.displayMessage(result); } } class ExecuteRemoteCommand{ private Context mContext; public ExecuteRemoteCommand(Context context) { mContext = context; } public void executeRemoteCommand( String username, String password, String hostname, int port, String command) { try { // Setting up the session with the details provided JSch jsch = new JSch(); Session session = jsch.getSession(username, hostname, port); session.setPassword(password); // Avoid asking for key confirmation Properties prop = new Properties(); prop.put("StrictHostKeyChecking", "no"); session.setConfig(prop); session.connect(); // SSH Channel ChannelExec channelssh = (ChannelExec) session.openChannel("exec"); ByteArrayOutputStream baos = new ByteArrayOutputStream(); channelssh.setOutputStream(baos); // Executing the command //channelssh.setCommand("ls"); channelssh.setCommand(command); channelssh.connect(); channelssh.disconnect(); // Letting the user know that a successful connection has been made to the remote computer //displayMessage("Connection Successful"); } catch (JSchException e) { //displayMessage("Connection Unsuccessful: " + e.toString()); } } public void displayMessage(final String in){ AlertDialog.Builder alertDialogBuilder = new AlertDialog.Builder( mContext); // set title alertDialogBuilder.setTitle("Your Title"); // set dialog message alertDialogBuilder .setMessage("Click yes to exit!") .setCancelable(false) .setPositiveButton("Yes",new DialogInterface.OnClickListener() { public void onClick(DialogInterface dialog,int id) { // if this button is clicked, close // current activity //mContext.finish(); } }) .setNegativeButton("No",new DialogInterface.OnClickListener() { public void onClick(DialogInterface dialog,int id) { // if this button is clicked, just close // the dialog box and do nothing dialog.cancel(); } }); // create alert dialog AlertDialog alertDialog = alertDialogBuilder.create(); // show it alertDialog.show(); } } ``` [https://pastebin.com/SxkNVPJ7](https://pastebin.com/SxkNVPJ7)
Android Async crashes when called from another class
CC BY-SA 3.0
0
2017-04-13T16:48:08.380
2017-04-16T14:25:07.033
2017-04-16T14:25:07.033
7,863,234
7,863,234
[ "java", "android", "android-asynctask", "mobile-development", "android-runonuithread" ]
43,430,892
1
43,430,952
null
-1
98
So I am new to iOS development and I have a question about the launch screen. My app will have an image (that loads when the app opens from the internet) this can change anytime the image is updated on the website, so what is the done thing when designing a launch screen as the image could be different to what is on the launch screen? Thanks
iOS development - launch screens where image on main screen can change?
CC BY-SA 3.0
null
2017-04-15T20:21:18.167
2017-04-15T20:27:01.160
null
null
7,346,480
[ "ios", "xcode", "mobile-development" ]
43,510,287
1
null
null
1
39
Gradle sync failed: No cached version of com.android.tools.build:gradle:2.2.3 available for offline mode. Consult IDE log for more details
Android studio error.I am a bigginer
CC BY-SA 3.0
null
2017-04-20T04:36:24.203
2017-04-20T04:36:24.203
null
null
7,279,382
[ "android-studio-2.3", "mobile-development" ]
43,604,019
1
43,778,778
null
0
348
I'm trying to download on my PC. Can anyone provide me with an offline installer of Smartface App Studio?
How do I get Smartface App Studio?
CC BY-SA 3.0
null
2017-04-25T07:16:06.633
2017-05-04T09:18:58.810
null
null
null
[ "android", "ide", "smartface.io", "mobile-development" ]
43,648,035
1
null
null
2
1,911
Basically I am trying to add an alarm feature to my app. >> >> when it's the time, But to do this, the app should wake itself to run the alarm feature; otherwise it won't work unless the app is running at the alarm time. Any regular alarm apps just open itself when its the time, even when the app was not running on the phone. does anyone here know how apps self-wake? Thanks very much
how to trigger a react-native app to wake up? (for alarm)
CC BY-SA 3.0
0
2017-04-27T03:14:42.143
2021-11-03T10:48:28.100
null
null
7,928,820
[ "android", "ios", "react-native", "mobile-development" ]
43,738,146
1
43,738,512
null
1
1,835
I am programming an Android App and I am trying to include a "change color" option (in a settings-screen for example). What I found out is that there are three colors in the "colors.xml" file (app->src->main->res->values): ``` <color name="colorPrimary">#3F51B5</color> <color name="colorPrimaryDark">#303F9F</color> <color name="colorAccent">#ff4040</color> ``` The idea is, if possible, to change those colors by a press on a button, for example (a red button will change to red theme, a blue one to blue theme, and so on). Is this anyhow possible? And if not, do you have a different idea to change colors? I'm sorry if a question like this already exists. I did not find anything but I also had no idea what to look for. Thank you in advance :) Edit: currently, I am trying it that way: ``` @Override public void onClick(View v) { switch (v.getId()) { case R.id.btn_dark: setTheme(R.style.BlackTheme); Toast.makeText(context, "Dark", Toast.LENGTH_SHORT).show(); break; case R.id.btn_light: setTheme(R.style.LightTheme); Toast.makeText(context, "Light", Toast.LENGTH_SHORT).show(); break; case R.id.btn_settings_save: Intent i = new Intent(SettingsActivity.this, MainActivity.class); startActivity(i); finish(); break; } } ``` Meaning, I want to change it by calling the onCreate in the MainActivity when pressing the save button I am trying to reset the "setContentView". Where do I have to set all the Themes? In the Manifest? Because when I set it in the OnCreate I will overwrite my changes done in the "settings"-Activity, or am I wrong with that?
Android Studio include "change color" options in app
CC BY-SA 3.0
null
2017-05-02T12:40:45.263
2017-05-07T10:15:48.310
2017-05-07T10:15:48.310
2,739,650
7,720,913
[ "android", "mobile-development" ]
43,770,192
1
43,771,279
null
-5
191
I want to develop an app for Android and iOS, which I will use camera, contacts, push notifications and maps I have some knowledge in Android and I have read a bit about react native, but I would like to know that other frameworks are there for development hybrid app or why should I use react native... Note: English isn't my native language
Why should I choose Native or hybrid app
CC BY-SA 3.0
null
2017-05-03T21:19:26.723
2017-05-03T22:56:12.577
null
null
5,995,311
[ "android", "ios", "hybrid-mobile-app", "react-native", "mobile-development" ]
43,843,093
1
null
null
7
16,913
I've been trying for a while now to get universal links of to work but it's not working till now. I have an apple-app-site-association configured. Have tried using the root domain, using a subfolder, on the same server or another. In all cases I am redirected to safari web page with a drop down to open my app as an option [](https://i.stack.imgur.com/KDrHC.png) What am I missing?
How to get a universal link to open the app instead of safari?
CC BY-SA 3.0
0
2017-05-08T08:32:26.437
2020-05-30T08:11:22.837
2017-05-08T09:15:11.060
1,063,706
1,063,706
[ "ios", "xcode", "ios-universal-links", "mobile-development" ]
43,865,711
1
43,891,325
null
-1
7,904
I want to use a tab layout in my ionic framework, so I started making it. By default it provides me 3 tabs, but now I want to add more tabs to it. I did it by making changes in the tabs folder and "tab.html" file. Now I want to do coding of the new tab pages which I just added in "tabs.html". So for this I created new folders of the new tabs inside the pages folder. Now I want to code the new tabs I have added. My question is how to do this. I tried by making new html file inside the folder of that page. But that gave me an error.. Please suggest me the solution as I am very new to ionic framework.
Adding new tabs in ionic framework
CC BY-SA 3.0
null
2017-05-09T09:11:12.273
2017-12-27T08:18:09.637
2017-05-10T04:48:43.873
6,900,386
6,900,386
[ "layout", "ionic-framework", "tabs", "mobile-development" ]
43,903,630
1
43,903,903
null
0
139
Thanks for taking the time to read my question. Basically I am developing a medication reminder app for Android. Rather than create a really basic UI, I really like the idea of having each question in a card. For example, in the first card I would like to have a TextView to say what the card is for and then an EditText for user input. Most cards would also have a TextView but a different kind of way for the user to input the required information, for example a Timepicker or Spinner. All I would really like to know is whether or not it is possible to use the Cardview in this manner? Once again, thank you so much for reading my question. Sarah
Cardview in Android - Can different cards be used to collect user information?
CC BY-SA 3.0
null
2017-05-10T22:23:52.927
2017-05-10T22:54:27.603
null
null
3,684,649
[ "android", "mobile-development" ]
43,967,700
1
null
null
0
262
As a short explanation: We are developing an Android App for the university. On the first screen is a list. This list is made by a ListView containing lots of TextViews. The following code is in our CustomListAdapter: ``` @Override public View getView(int position, View convertView, ViewGroup parent) { View v = super.getView(position, convertView, parent);//let the adapter handle setting up the row views v.setBackgroundColor(mContext.getResources().getColor(android.R.color.transparent)); if (mSelection.get(position) != null) { v.setBackgroundColor(mContext.getResources().getColor(android.R.color.holo_blue_light)); } return v; } ``` I found out, that the line inside the if statement: `v.setBackgroundColor(mContext.getResources().getColor(android.R.color.holo_blue_light));` sets the color for the selected items of our list. Is there a way to change this color for different themes? So that it is for example like this (blue) in one theme, but orange or something in a diferent theme. I tried it with different solutions like that one: ``` <style name="BlackTheme" parent="Theme.AppCompat"> <item name="colorAccent">@android:color/holo_orange_dark</item> <item name="android:actionModeStyle">@style/MyActionBar</item> </style> <style name="MyActionBar" parent="Base.Widget.AppCompat.ActionBar"> <item name="android:background">@android:color/holo_orange_light</item> </style> ``` for `android:background`I used multiple different attributes, but none of them worked until now. I also tried setting `v.setBackgroundColor(mContext.getResources().getColor(android.R.color.holo_blue_light));` to `v.setBackgroundColor(mContext.getResources().getColor(R.color.selectedItem));`, this color is set as the following: `<color name="selectedItem">?attr/selectableItemBackground</color>` and my style containes the line `<item name="android:selectableItemBackground">@android:color/holo_orange_light</item>`. This also does not work, because it throws an error of type "android.content.res.Resources$NotFoundException: Resource ID #0x7f0b0054 type #0x2 is not valid" Thanks in advance :)
Change color of "highlight" in ContextualActionMode for different theme
CC BY-SA 3.0
null
2017-05-14T18:56:42.827
2017-05-17T06:51:20.850
2017-05-17T06:51:20.850
7,720,913
7,720,913
[ "android", "textview", "android-actionmode", "mobile-development" ]
44,189,419
1
null
null
0
93
I am trying to make an app that can view my ipcam. I tried doing it by using my webview ``` } String url = "http://"; WebView view = (WebView) this.findViewById(R.id.glennView); view.getSettings().setJavaScriptEnabled(true); view.loadUrl(url); } ``` But it is telling me that the user name and password is wrong. When I type in the `URL` in my web browser it does ask for my username and password. But not through the app. Can anyone help me with this ? thanks in advance Stephen
I can't login in my ip-cam through webview
CC BY-SA 3.0
null
2017-05-25T20:36:51.263
2017-05-26T05:02:07.837
2017-05-26T05:02:07.837
1,796,579
3,997,063
[ "android", "webview", "ip-camera", "login-script", "mobile-development" ]
44,501,963
1
48,960,989
null
-1
663
Is it possible in iOS to open any mail attachment in Mobile Safari. I have tried these: it does not show option to open the file in safari. javascript is disabled in document preview so it is not working.
Open Attachments In Mobile Safari
CC BY-SA 3.0
null
2017-06-12T14:29:36.937
2018-02-24T08:41:54.070
2017-06-12T14:48:29.787
418,074
418,074
[ "ios", "objective-c", "iphone", "mobile-development", "hackintosh" ]
44,673,102
1
44,673,171
null
0
63
I am new to android and wondering if anyone can help me by pointing me or giving me a code example (preferably) on how to update my UI values (simple text view value) from a response from my server (JSON object). my j son is `{num : 1, val: 22}`. Thank you
How to update my UI values in android?
CC BY-SA 3.0
null
2017-06-21T10:09:05.127
2017-06-21T10:32:18.297
2017-06-21T10:32:18.297
8,193,423
8,193,423
[ "java", "android", "json", "mobile-development" ]
44,837,859
1
null
null
-1
598
How to get the raw value from a enum passing the key value? Must work for any enum types working like an extension of enum types. Any mirror reflection, mappable or RawRepresentable solutions are welcome. I would like something like this: ``` enum Test : String { case One = "1" } Test.rawValueFromKey(keyValue: "One") // Must return "1" // I don't want the solution below, I must get the rawValue through the key name as String. Test.One.rawValue ``` I do need to get the rawValue passing the name of the key as a String. Otherwise, I will need to make a switch or many if/else conditions. I have a big Enum and I don't want to check the string passed in a switch for example and pass `Test.One.rawValue`. I would like to get the rawValue directly through the key as String, just like in a dictionary. I also don't want the code below, because I have a Enum of 40 items and I think it is ugly to make a switch of 40 items. ``` switch keyValue { case "One": return Test.One.rawValue break } ``` I want something like this: ``` func rawValueFromKey (keyValue: String) -> Test { // code here to get the rawValue through the keyValue as String // return the proper Test Enum } ``` I tried some possible solutions using Mirror reflection and enum iterations to find the rawValue through the keyValue but didn't work. Please give the solution in both Swift 2 and 3. Thanks
Enum Types: get raw value from key
CC BY-SA 3.0
0
2017-06-30T02:50:58.960
2022-10-16T11:32:15.787
2017-06-30T18:18:10.933
1,002,156
1,002,156
[ "ios", "swift", "mobile-development" ]
44,859,800
1
null
null
0
33
Sorry if my question is phrased badly, but I'm currently developing an icon pack for android that does not have its own dedicated app, and it shouldn't. I am currently using this: [https://forum.xda-developers.com/showthread.php?t=2399426](https://forum.xda-developers.com/showthread.php?t=2399426) as source code (since I'm an android noob) and am having difficulty trying to stop the "open" being an option after the installation of the icon pack, as it simply takes the user to a blank app activity. Please keep in mind that I am a total noob and have very little experience in java. If it's possible, could someone simply point me in the direction of the file and line I should edit/add to solve my problem? Thanks!
How to not make my app openable?
CC BY-SA 3.0
null
2017-07-01T10:20:01.180
2017-07-01T14:40:30.897
null
null
8,240,720
[ "android", "icons", "customization", "mobile-development" ]
44,947,942
1
44,948,711
null
4
5,659
I'm trying to wrap my head around how to implement iOS/Android finger print to authenticate a user. From what I understand, triggering the finger print dialog is just an additional security? So a typical on boarding process would be something like this: 1. User downloads the app. 2. User registers/signs in, and get a token back from the server. 3. On certain actions where we need additional security, trigger finger print dialog. 4. If fingerprint is OK - do actual REST call with token from step 2. Am I missing something?
iOS/Android finger print - authentication server side
CC BY-SA 3.0
0
2017-07-06T11:44:50.753
2017-07-06T12:19:43.597
null
null
296,030
[ "android", "ios", "security", "fingerprint", "mobile-development" ]
45,047,855
1
null
null
0
36
I have certain windows mobile devices which supposed to be only connected to a known wifi network. so the user of the device can not connect to other wifi network as they intend. how can i tackle this problem. your kind guidance is required. i know this is constrained by many hard factors. but i would like to know if there is a way. Thank you first i thought watching and deleting wifi network profiles. but am afraid performing such things will allow on windows mobile. then i to find a way to close other application connection if its connected to unwanted network. then i tried to find a way to write a driver to mobile device driver (though it is a tough task) ,at least to understand the possibility
how to monitor wifi networks and remove them in windows mobile..?
CC BY-SA 3.0
null
2017-07-12T03:23:46.347
2017-07-12T03:23:46.347
null
null
8,219,674
[ "wifi", "windows-mobile", "device-driver", "mobile-development" ]
45,148,134
1
null
null
1
288
This is my code: ``` public class CustomDialog extends DialogFragment { @NonNull @Override public Dialog onCreateDialog(Bundle savedInstanceState) { AlertDialog.Builder myDialogBuilder = new AlertDialog.Builder(getActivity()); myDialogBuilder.setTitle("Get Ready To Rumble!"); myDialogBuilder.setMessage("Do you wanna rumble?!"); myDialogBuilder.setPositiveButton( new DialogInterface.OnClickListener() { @Override public void onClick(DialogInterface dialog, int which) { Toast.makeText(. this, "Let's Rumble!", Toast.LENGTH_SHORT).show(); } } ) return myDialogBuilder.create(); } ``` } There seems to be an error of the content at the line : ``` Toast.makeText(CustomDialog.this, "Let's Rumble!", Toast.LENGTH_SHORT).show(); ``` I've tried just typing "this", "DialogFragment.this"... Can't seem to find out the problem. Hope you guys can help me, sorry for the long code.
Can't find context in makeText() while making a Toast
CC BY-SA 3.0
null
2017-07-17T15:29:52.827
2017-07-17T19:35:40.827
null
null
8,178,804
[ "android", "toast", "mobile-development" ]
45,165,010
1
null
null
0
76
I use react-native for my school project and like the official documentation, I use the following command to create new project : ``` create-react-native-app AwesomeProject ``` it creates a project with the latest react native package such as : ``` "react": "16.0.0-alpha.12", "react-native": "^0.45.1", ``` Now, I would like use "react-number-format" in my project but, I always have a problem of dependencies. ``` npm WARN [email protected] requires a peer of react@^0.14 || ^15.0.0-rc || ^15.0.0 but none was installed. npm WARN [email protected] requires a peer of react-dom@^0.14 || ^15.0.0-rc || ^15.0.0 but none was installed. ``` And I have an error when I try to use the library (just with import). Can Anyone help me? NB : Anothers libraries use "react": "16.0.0-alpha.12" as dependence so I can't change it
Error of dependencies with react-native
CC BY-SA 3.0
null
2017-07-18T11:06:19.020
2017-07-18T11:20:06.017
null
null
8,319,468
[ "react-native", "mobile-development" ]
45,182,270
1
null
null
-2
132
Mobile App Development -Native (java,swift) -Xamarin -React Native -ionic -what else? ...Which should I choose to use in the future and why? I'm Thai ,Sorry for my language ...Thank U
Mobile App Development ...Which should I choose to use in the future?
CC BY-SA 3.0
null
2017-07-19T06:13:54.367
2017-07-19T10:05:17.460
2017-07-19T06:17:41.037
8,318,328
8,318,328
[ "mobile-development" ]
45,230,907
1
null
null
2
637
I want to change the sound of remote notifications in iOS. But I do not want to send the sound name in push payload. I want to set it from the device itself. This is possible in Android. But no idea how to do it in iOS. Please help. Thanks,
How to change sound of iOS remote notifications without changing push payload
CC BY-SA 3.0
null
2017-07-21T06:52:08.477
2017-07-21T07:06:35.820
null
null
6,880,456
[ "ios", "objective-c", "mobile-development" ]
45,275,109
1
45,276,185
null
0
1,400
I have an AlertController which pops after adding a new note. It has two options: "new note" and "see notes". When press "see notes", it should enter another pages to see list of notes. When press "new note", it should stay on this page for adding a new note. So, how to enter another page pressing an alertCtrl option button? Now I have: ``` showConfirm() { let confirm = this.alertCtrl.create({ title: 'What do you want to do else?', buttons: [ { text: 'New note', handler: () => { console.log('New note'); } }, { text: 'See notes', handler: () => { console.log('See notes'); } } ] }); confirm.present(); ``` [](https://i.stack.imgur.com/FRv6Y.png)
Enter another page when pressing AlertController's option buttons ionic
CC BY-SA 3.0
0
2017-07-24T07:58:35.773
2017-07-24T08:53:55.013
null
null
6,200,054
[ "angular", "typescript", "ionic-framework", "mobile-development" ]
45,323,451
1
45,340,380
null
8
16,387
I've added a toolbaritem in my app, however i dont see a way to change its background and text color. ``` <ContentPage.ToolbarItems> <ToolbarItem Text="About" Icon="ic_action_more_vert.png" Priority="0" Order="Secondary" Clicked="ToolbarItem_Clicked"/> <ToolbarItem Text="Settings" Icon="ic_action_more_vert.png" Priority="0" Order="Secondary"/> </ContentPage.ToolbarItems> ``` This is what I'd like changed. The black menu with white text, want to change that bg color and text color. Any idea how to achieve this? [](https://i.stack.imgur.com/hFkbx.jpg)
Change color of ToolBarItem in XAML
CC BY-SA 3.0
0
2017-07-26T09:53:16.330
2020-04-08T16:28:12.553
null
null
null
[ "xaml", "xamarin.android", "xamarin.forms", "mobile-development" ]
45,355,454
1
45,358,387
null
-3
443
I would like to know what are the best practices regarding, Modeling data when no network connection available, if the app you are building is cloud computing based, but still you want to be able to have basic functionality and I guess some persistent data? PD: I am kind of new to IOS development
When offline, how to manage data? IOS
CC BY-SA 3.0
0
2017-07-27T15:45:46.910
2017-07-27T18:24:08.313
null
null
8,377,232
[ "ios", "swift", "mobile-development" ]
45,611,166
1
null
null
0
811
I'm using react-native for developing android and ios app. I know nothing about ios-development and Xcode environment. When i run `react-native run-ios` i see this error: ``` ld: library not found for -lRNSVG-tvOS clang: error: linker command failed with exit code 1 (use -v to see invocation) ** BUILD FAILED ** ``` Any ideas? : This might be caused by react-native-svg or react-native-vector-icons package.
react-native library not found for -lRNSVG-tvOS
CC BY-SA 3.0
0
2017-08-10T10:27:25.507
2019-02-05T14:23:33.737
null
null
5,923,192
[ "ios", "xcode", "react-native", "react-native-ios", "mobile-development" ]
45,738,649
1
null
null
1
409
``` react-native -v: 0.47.0 npm ls rnpm-plugin-windows: 0.47.0-RC5 npm ls react-native-windows: yes node -v:8.2.1 npm -v:5.3.0 yarn --version:n/a ``` ``` Target Platform: UWP (developer mode enabled) Target Platform Version(s): 10.0.10586 .NET 4.6.1, .NET 4.5 Target Device(s): Mobile ARM Development Operating System: Windows 10 Desktop Visual Studio Version: Visual Studio 2015 Visual Studio 2017 ``` - - - - - - - - - - - - App should load on the screen showing the contents of index.windows.js page Error message stating unable to download JS Bundle. [](https://i.stack.imgur.com/cErab.png) (Paste the link to an example project and exact instructions to reproduce the issue.) [https://github.com/ballySingh/repo2.git](https://github.com/ballySingh/repo2.git) Download the zip and run npm install. Please follow step 4 from the reproduction section, above.
Unable to download JS bundle on UWP React Native
CC BY-SA 3.0
null
2017-08-17T15:01:15.100
2021-07-21T01:25:06.057
2017-08-17T20:12:11.633
1,849,060
1,849,060
[ "react-native", "uwp", "windows-10-mobile", "mobile-development", "react-native-windows" ]
45,742,606
1
null
null
1
373
I want to stream live mp3 from a server (MP3 NOT MP4) and here is what i already have. I will give a piece of code from my project. ``` def worker(self, v): if len(self.musicTitle) > 50: self.album.text = self.musicTitle[:50]+" .." else: self.album.text = self.musicTitle self.pltitle.text = "Music Now Playing" self.pp.text = "%s"%(icon("fa-pause-circle-o", 60, "#dcdcdc")) MediaPlayer = autoclass('android.media.MediaPlayer') AudioManager = autoclass('android.media.AudioManager') self.mPlayer = MediaPlayer() self.mPlayer.reset() self.mPlayer.setAudioStreamType(AudioManager.STREAM_MUSIC) self.mPlayer.setDataSource(self.sUrl) #self.mPlayer.prepare() self.mPlayer.prepareAsync() #time.sleep(duration) #If i use java mediaPlayer.setOnPreparedListerner it crashes my app, so i should find a workaround self.isR = Clock.schedule_interval(self.isReady, 1)#I use this to check if a player is ready to play alt to java setOnPreparedListerner def isReady(self, isr): dr = self.mPlayer.getDuration() if len(str(dr)) == 1: self.seeker.value = 0 self.start.text = '0:00' self.end.text = '0:00' self.buffer.text = 'Buffering' #NOT READY else: #READY Clock.unschedule(self.isR) self.mPlayer.start() self.canControl = True self.buffer.text = '' if self.canControl: self.duration = self.mPlayer.getDuration()/1000 #Convert to sec self.seeker.max = self.duration self.end.text = str(getTime.getTime(self.duration)) self.upW = Clock.schedule_interval(self.updateWidget, 1) def control(self): if self.canControl: if self.mPlayer.isPlaying(): self.length = self.mPlayer.getCurrentPosition()/1000 self.mPlayer.pause() self.pp.text = "%s"%(icon("fa-play-circle-o", 60, "#dcdcdc")) else: if not self.length: self.length = self.mPlayer.getCurrentPosition()/1000 self.mPlayer.seekTo(self.length) self.mPlayer.start() self.pp.text = "%s"%(icon("fa-pause-circle-o", 60, "#dcdcdc")) def close(self): if self.canControl: self.canControl = False Clock.unschedule(self.upW) Clock.unschedule(self.isR) self.mPlayer.stop() self.mPlayer.release() self.mPlayer = None def seekValue(self, value): if self.canControl: self.mPlayer.seekTo(value*1000) def updateWidget(self, q): if self.canControl: self.seeker.value = self.mPlayer.getCurrentPosition()/1000 self.start.text = str(getTime.getTime(self.mPlayer.getCurrentPosition()/1000)) if self.seeker.value == self.seeker.max or self.seeker.value > self.seeker.max:#Check if a music is finished self.pp.text = "%s"%(icon("fa-play-circle-o", 60, "#dcdcdc")) self.mPlayer.seekTo(0) self.mPlayer.pause() def loopMusic(self): if self.isLoop: self.isLoop = False self.mPlayer.setLooping(False) self.replay.text = "%s"%(icon("fa-retweet", 30, "#EEEFFF")) else: self.isLoop = True self.mPlayer.setLooping(True) self.replay.text = "%s"%(icon("fa-retweet", 30, "#15def9")) ``` The above code works BUT for some reasons android MediaPlayer is Very Very Very slow it may sometimes take 2min to prepare a stream. Now is there any other way i can stream audio in android and/or in Ios with python kivy without a long buffering time (I also don't want to use ffmpeg or/and ffpyplayer they both NOT WORKING and support only mp4)
Kivy - Android & Ios audio streaming
CC BY-SA 3.0
null
2017-08-17T18:30:14.653
2017-08-17T18:30:14.653
null
null
3,921,145
[ "android", "python", "ios", "kivy", "mobile-development" ]
45,796,065
1
null
null
-3
65
I have an idea for a game which consists of adding elements on certain web pages in a player's browser on Android/iOS. It has to be their native browser and not a custom one for this game, as the idea is to play whenever you enter a certain site when doing normal browsing. A very rough outline when a user enters a site would be: 1. Check with a server if the website is part of the game 2. If so, add a textbox or an image to the website using javascript Is this possible to do? Would it be allowed on app stores? If so, what tools/frameworks would be the best option?
How can I manipulate the client-side appearance of websites on Android/iOS using JavaScript for a mobile game?
CC BY-SA 3.0
null
2017-08-21T11:33:08.053
2017-08-21T13:36:45.590
2017-08-21T13:36:45.590
8,494,672
8,494,672
[ "javascript", "android", "ios", "mobile-development" ]
45,966,749
1
46,033,914
null
-1
704
I tried to get contacts i saw that it need some time to wait. So, i tried to do it in async task with writting contacts to app db. Here is my failed attempt: ``` public class GetUpdateContactsTask extends AsyncTask<Void, Contact, Void> { private static final String TAG = "lifeCycle"; private Context mContext; public GetUpdateContactsTask (Context context){ mContext = context; } public interface OnFinishListener{ void onFinish(); } public OnFinishListener finishListener; public void setFinishListener(OnFinishListener finishListener){ this.finishListener = finishListener; } @Override protected void onPreExecute() { } @Override protected Void doInBackground(Void... params) { ContentResolver cr = mContext.getContentResolver(); Cursor cur = cr.query(ContactsContract.Contacts.CONTENT_URI, null, null, null, null); if (cur.getCount() > 0) { // here is an NullPointerException error while (cur.moveToNext()) { String id = cur.getString(cur.getColumnIndex(ContactsContract.Contacts._ID)); String name = cur.getString(cur.getColumnIndex(ContactsContract.Contacts.DISPLAY_NAME)); if (cur.getInt(cur.getColumnIndex(ContactsContract.Contacts.HAS_PHONE_NUMBER)) > 0) { Cursor pCur = cr.query( ContactsContract.CommonDataKinds.Phone.CONTENT_URI, null, ContactsContract.CommonDataKinds.Phone.CONTACT_ID +" = ?", new String[]{id}, null); while (pCur.moveToNext()) { String phoneNo = pCur.getString(pCur.getColumnIndex(ContactsContract.CommonDataKinds.Phone.NUMBER)); Contact contact = new Contact(); contact.setName(name); contact.setPhoneNumber(phoneNo); publishProgress(contact); } pCur.close(); } } } return null; } @Override protected void onProgressUpdate(Contact... values) { Contact contact = values[0]; String name = contact.getName(); String phoneNumber = contact.getPhoneNumber(); if (!phoneNumber.equals("not valid")){ Log.e(TAG, name + ": " + phoneNumber); if(!DataHelper.getInstance().isContactIsset(values[0])){ DataHelper.getInstance().saveContact(values[0]); Log.e(TAG, "contact saved"); } else { Log.e(TAG, "contact is isset"); } } } @Override protected void onPostExecute(Void aVoid) { super.onPostExecute(aVoid); finishListener.onFinish(); } ``` } it's not work. There is a nullpointerexception error on cursor. It will good if you help to correct my version, but it will great if you show your better solution. Thanks
how to get phone contacts in async task?
CC BY-SA 3.0
null
2017-08-30T17:45:34.137
2019-04-15T21:42:21.847
2017-09-04T09:15:22.130
5,292,302
4,197,390
[ "java", "android", "mobile-development" ]
46,219,438
1
46,222,163
null
2
2,505
Im new to android I'm using content provider in my application, In my application I want to join two tables but I don't know how to do it, please help me find out solution my tables: ``` CREATE TABLE Bank_customers (customer_id varchar PRIMARY KEY , customer_name varchar, customer_date_of_birth date, address varchar, mobile integer, email varchar); CREATE TABLE Bank_accounts (account_number integer(11) PRIMARY KEY, customer_id varchar , account_type text, account_open_date date, account_balance real,FOREIGN KEY(customer_id) REFERENCES Bank_customers(customer_id)); my query: **SELECT mobile,Bank_accounts.customer_id from Bank_accounts,Bank_customers WHERE Bank_customers.customer_id = Bank_accounts.customer_id and Bank_accounts.account_number = 13323;** ``` How I can implement above query using content provider class "query method"
how to join two tables in android using content provider query method?
CC BY-SA 3.0
0
2017-09-14T12:39:21.730
2017-09-14T15:17:00.050
2017-09-14T12:51:16.423
7,762,393
6,215,208
[ "java", "android", "sqlite", "kotlin", "mobile-development" ]
46,235,959
1
null
null
-1
765
Anyone have any best idea to work Android application online as well as offline? Also, how can I manage server side data sync with the local database?
How to make android application work online and offline both with server side? and how to sync the server side data?
CC BY-SA 3.0
null
2017-09-15T09:13:25.293
2017-09-15T09:46:04.600
2017-09-15T09:25:11.577
2,724,879
7,859,569
[ "android", "realm", "retrofit", "mobile-development" ]
46,267,665
1
46,270,134
null
1
179
I try to create a button dynamically with in Java and add it some constraints to position it in the center of my constrainLayout. So I write this code: ``` import android.app.Activity; import android.os.Bundle; import android.support.constraint.ConstraintLayout; import android.support.constraint.ConstraintSet; import android.widget.Button; public class SelectGameActivity extends Activity { @Override protected void onCreate(Bundle savedInstanceState) { super.onCreate(savedInstanceState); setContentView(R.layout.activity_select_game); ConstraintSet constraintSet = new ConstraintSet(); ConstraintLayout constraintLayout = findViewById(R.id.constraintLayout); constraintSet.clone(constraintLayout); Button button = new Button(this); button.setText("test"); button.setId(213); constraintLayout.addView(button); constraintSet.connect(button.getId(), ConstraintSet.LEFT, R.id.constraintLayout, ConstraintSet.LEFT); constraintSet.connect(button.getId(), ConstraintSet.RIGHT, R.id.constraintLayout, ConstraintSet.RIGHT); constraintSet.connect(button.getId(), ConstraintSet.TOP, R.id.constraintLayout, ConstraintSet.TOP); constraintSet.connect(button.getId(), ConstraintSet.BOTTOM, R.id.constraintLayout, ConstraintSet.BOTTOM); constraintSet.applyTo(constraintLayout); } } ``` It works but the button fills all the screen: [](https://i.stack.imgur.com/ZYBlE.png) I think it is because my button doesn't have any specific height and width. I tried several codes to give it a size but no effect. Could someone give me some hints to resize my button correctly ? Thank you very much ! Charles
Android - Resize UI widget created dynamically
CC BY-SA 3.0
null
2017-09-17T18:47:02.497
2017-09-18T04:56:02.477
2017-09-18T04:56:02.477
7,663,565
2,170,573
[ "android", "android-layout", "android-constraintlayout", "mobile-development" ]
46,350,899
1
null
null
-2
47
So I'm doing some research and am a little lost as I don't have any experience in regards to the dev side of applications. I've got a few questions and would greatly appreciate some help: 1) Is there any full device encryption for Android mobile devices? I didn't see any 3rd party apps that did this but I can't believe this would be the case unless... 2) Do 3rd party apps have permission to do such a things? If not, can they encrypt personal files/folders? 3) Where can I go to find out more about the permissions of 3rd party apps? Thank you for your time!
Mobile Device (Android) Encryption
CC BY-SA 3.0
null
2017-09-21T18:29:14.437
2017-09-24T16:02:12.017
null
null
6,879,464
[ "android", "encryption", "android-permissions", "mobile-application", "mobile-development" ]
46,476,729
1
46,477,906
null
1
769
I have an API which returns text which contains some HTML entities, e.g. `&nbsp;`. This is handled nicely on web and shown as space, but on mobile apps it's shown as text with value `&nbsp`. I use `React Native`, but I think the issue would also happen if I was coding in `Android` or `Ojbective-C`. What is the general approach for showing HTML entities on mobile apps, just like they are shown on the web? I tried [he](https://github.com/mathiasbynens/he) in order to encode the strings and decode them afterwards. It worked for some examples, but for instance for `&nbsp` it didn't work. Thanks :)
Convert html entities for mobiles
CC BY-SA 3.0
null
2017-09-28T19:17:42.880
2017-09-28T20:38:07.517
null
null
4,122,928
[ "javascript", "mobile", "react-native", "html-entities", "mobile-development" ]
46,516,042
1
null
null
1
1,047
Hello this is the first time using Xamarin. What I am trying to do is modify this application to use ListView, but first I would like to learn how to get a value from a stepper and print it to the label. I know movieamount sends the value selected from the stepper and sends it to the totalLabel text, but I can't seem to figure out how to send it to the label with 0 already and have it change values when selected. It does return the correct amount selected but never prints to the screen. ``` public static string movieamount; public static string pickmovie; public static string paymentSelected; public static string dateSelected; public static string timeSelected; public static string totalLabel; public MainPage() { Picker picker = new Picker { Title = "Movies", VerticalOptions = LayoutOptions.CenterAndExpand }; var options = new List<string> { "Kill Bill", "Matrix", "Zombieland", "The Dark Knight", "Terminator", "Apocalypse Now", "Resouvoir dogs", "Horrible Bosses", "The Breakup", "Wedding Crashers", }; picker.SelectedIndexChanged += (sender, e) => { pickmovie = picker.Items[picker.SelectedIndex]; }; foreach (string optionName in options) picker.Items.Add(optionName); //listView.ItemTapped += async (sender, e) => { await DisplayAlert("Tapped", e.Item.ToString() + " was selected.", "OK"); ((ListView)sender).SelectedItem = null; }; //this.Content = listView; Label valuelabel = new Label { Text = "0", FontAttributes = FontAttributes.Bold, FontSize = 30, HorizontalOptions = LayoutOptions.Center }; Stepper stepper = new Stepper { Minimum = 0, Maximum = 10, Increment = 1, HorizontalOptions = LayoutOptions.Center, VerticalOptions = LayoutOptions.CenterAndExpand }; stepper.ValueChanged += (sender, e)=> { movieamount = stepper.Value.ToString(); }; Picker payment = new Picker { Title = "Payment Method", VerticalOptions = LayoutOptions.CenterAndExpand }; var options1 = new List<string> {"Visa", "MasterCard", "AmericanExpress", "Free",}; foreach (string optionName in options1) payment.Items.Add(optionName); payment.SelectedIndexChanged += (sender, e) => { paymentSelected = payment.Items[payment.SelectedIndex]; }; //TimePicker was here Label totalLabel = new Label { HorizontalOptions = LayoutOptions.CenterAndExpand, FontSize = 40, FontAttributes = FontAttributes.Bold | FontAttributes.Italic }; DatePicker datePicker = new DatePicker { Format = "D", VerticalOptions = LayoutOptions.CenterAndExpand, }; //---Handle Inline--- datePicker.DateSelected += (object sender, DateChangedEventArgs e) => { //eventValue.Text = e.NewDate.ToString(); dateSelected = e.NewDate.ToString(); }; TimePicker timePicker = new TimePicker { Format = "T", VerticalOptions = LayoutOptions.CenterAndExpand }; // set inline handler timePicker.PropertyChanged += (sender, e) => { if (e.PropertyName == TimePicker.TimeProperty.PropertyName) { timeSelected = timePicker.Time.ToString(); }; }; Button button = new Button { Text = "Submit", FontSize = Device.GetNamedSize(NamedSize.Large, typeof(Button)), HorizontalOptions = LayoutOptions.CenterAndExpand, VerticalOptions = LayoutOptions.Fill }; button.Clicked += (sender, args) => { totalLabel.Text = "You have ordered " + movieamount + " " + pickmovie + " \n You will be paying with " + paymentSelected + " " + "Your delivery will be delivered at " + dateSelected + " " + timeSelected; }; StackLayout stackLayout = new StackLayout { Children = { picker, payment, valuelabel, stepper, datePicker, totalLabel, timePicker, button, } }; BackgroundColor = Color.Yellow; this.Content = stackLayout; } } ``` }
Send value to label from Stepper Xamarin.form
CC BY-SA 3.0
null
2017-10-01T19:24:24.550
2017-10-01T23:43:25.830
null
null
6,924,089
[ "c#", "xamarin", "xamarin.ios", "xamarin.android", "mobile-development" ]
46,549,490
1
null
null
0
122
I'm researching on how to make a swiping menu dial. [Like This](https://www.dropbox.com/s/icqlj4n0xsf4c71/Screen%20Shot%202017-10-03%20at%209.34.09%20AM.png?dl=0) Since it is a mobile app, my idea is to allow the user to swipe their finger around the dial to move and see all the button options on the menu. I was thinking of using some sort of scrolling touch feature that could let the user keep swiping left or right till they see the same button options as it makes its way back completely around the dial. Anyone have an idea to recreate this menu dial? Thanks in advance!! - Jemma
React-Native: How can I program a scroll that allows elements in a menu reappear once it has made its way around?
CC BY-SA 3.0
null
2017-10-03T16:40:35.750
2017-10-03T17:00:13.357
2017-10-03T17:00:13.357
7,017,647
7,017,647
[ "javascript", "ios", "react-native", "swiper.js", "mobile-development" ]
46,631,886
1
null
null
0
21
I want to start IOS development as i prefer ios over android and other platforms due to personal liking only. The problem is i tried Visual Studio with Xamarin but it needs an actual MAC for apps !! I am thinking about using Xamarin Studio! Does it require a MAC too ? Any other way around without using VM or MAC ?
Without using VM or MAC how can i do IOS development
CC BY-SA 3.0
null
2017-10-08T13:57:50.280
2017-10-08T14:24:56.580
null
null
3,682,810
[ "c#", "ios", "mobile-development" ]
46,646,644
1
null
null
0
83
Can someone explain why this code is not working as expected? As you can see, I'm using loop to create imageViews with gestureRecognizers. I don't understand why only the first imageView's gestureRecognizer is working. I hope someone can help. Thank you! [](https://i.stack.imgur.com/0JuEu.jpg) ``` for (int i = 0; i < tenderList.count; i++) { UIImageView *imageView = [[UIImageView alloc] init]; imageView.backgroundColor = [UIColor grayColor]; imageView.tag = 100 + i; imageView.contentMode = UIViewContentModeScaleAspectFit; [imageView sd_setImageWithURL:[NSURL URLWithString:[tenderList objectAtIndex:i].imageUrl]]; [imageView setUserInteractionEnabled:YES]; UITapGestureRecognizer *click = [[UITapGestureRecognizer alloc] initWithTarget:self action:@selector(tenderSelected:)]; [imageView addGestureRecognizer:click]; UIView *row = [rowArray objectAtIndex:i]; [row addSubview:imageView]; [imageView mas_makeConstraints:^(MASConstraintMaker *make) { make.left.equalTo(@20); make.right.equalTo(@-20); make.centerY.equalTo(row); make.height.equalTo(row).multipliedBy(0.8); }]; } ```
Using loop to create dynamic ImageViews and GestureRecognizers
CC BY-SA 3.0
null
2017-10-09T12:37:17.023
2017-10-09T17:15:11.033
2017-10-09T17:15:11.033
3,231,194
null
[ "ios", "objective-c", "mobile-development" ]
46,989,504
1
null
null
1
207
Im newbie at android development. Trying to create a working video player but get errors. When click on a play button there is only sound no video and black screen. Tried some suggested solutions - nothing help. Here's the code: ``` import android.media.MediaPlayer; import android.net.Uri; import android.os.Bundle; import android.support.v7.app.AppCompatActivity; import android.view.View; import android.widget.Button; import android.widget.MediaController; import android.widget.VideoView; public class MainActivity extends AppCompatActivity { Button btn; VideoView videoView; MediaController mediaController; @Override protected void onCreate(Bundle savedInstanceState) { super.onCreate(savedInstanceState); setContentView(R.layout.activity_main); videoView = (VideoView) findViewById(R.id.vdView); btn = (Button) findViewById(R.id.startBtn); mediaController = new MediaController(this); } public void startVideo(View view) { String filePath = "android.resource://" + getPackageName()+ "/" + R.raw.cartoon; Uri uri = Uri.parse(filePath); videoView.setVideoURI(uri); mediaController.setAnchorView(videoView); videoView.setOnPreparedListener(new MediaPlayer.OnPreparedListener() { public void onPrepared(MediaPlayer mp) { videoView.start(); } }); } } ``` Errors in console: ``` D/MediaPlayer: getMetadata E/MediaPlayer: error (1, -38) E/MediaPlayer: error (1, -38) E/MediaPlayer: error (1, -38) E/MediaPlayer: Error (1,-38) D/VideoView: Error: 1,-38 E/MediaPlayer: Error (1,-38) D/VideoView: Error: 1,-38 E/MediaPlayer: Error (1,-38) D/VideoView: Error: 1,-38 D/EGL_emulation: eglMakeCurrent: 0x7f889b45a660: ver 2 0 D/EGL_emulation: eglMakeCurrent: 0x7f889b45a660: ver 2 0 D/EGL_emulation: eglMakeCurrent: 0x7f889b45a660: ver 2 0 D/EGL_emulation: eglMakeCurrent: 0x7f889b45a660: ver 2 0 I/Choreographer: Skipped 47 frames! The application may be doing too much work on its main thread. ``` HOW TO FIX IT?
VideoView - no video but sound when played
CC BY-SA 3.0
null
2017-10-28T12:01:57.897
2017-10-28T12:01:57.897
null
null
8,041,102
[ "android", "mobile-development" ]
47,168,191
1
50,894,191
null
2
3,307
I am new to REALM and I am trying to join two tables but I can't find information of sql query for realm (I am using React Native) Tables are ChatRoom and Message. ChatRoom has multiple Messages. I would like to get all chatrooms with only one most lastest message for each chatroom. ``` ChatRoom.schema = { name: 'fcm_chat_room', primaryKey: 'chat_room_id', properties: { chat_room_id: 'string', chat_room_name: {type: 'string', default: ''}, chat_room_date: 'date' } }; Message.schema = { name: 'fcm_message', primaryKey: 'message_id', properties: { message_id: 'string', chat_room_id: 'string', sender_id: 'string', sender_reg_id: 'string', message: 'string', msg_date: 'date', is_read: {type: 'bool', default: false} } }; ```
How can I join two tables with REALM
CC BY-SA 3.0
0
2017-11-07T22:03:31.363
2018-06-17T06:15:28.323
null
null
3,466,549
[ "react-native", "realm", "mobile-development" ]
47,191,110
1
47,204,070
null
1
281
I got SKSpriteNode of hero in my GameScene. I implement two buttons (up and down). I need that SKSpriteNode of my hero is moving up and down by buttons touches. But i only see touchesMoved and touchesEnded methods. I need something about touchesBegan (that feel the button tap while i tap it).
Move SKSpriteNode by button touch
CC BY-SA 3.0
null
2017-11-08T22:54:55.813
2017-11-09T14:15:17.013
2017-11-09T00:12:20.973
7,710,399
7,710,399
[ "swift", "xcode", "sprite-kit", "mobile-development" ]
47,251,276
1
null
null
-2
32
There are various tasks that a web back end developer has to do while doing a project while making APIs in specific. For example setting up authorizations for various roles, setting up a push notification server(mobile applications) etc. I just wanted to know a few more.
What are the most redundant tasks (authentication, social network integration etc.) in the life of a back-end web developer?
CC BY-SA 3.0
null
2017-11-12T16:41:47.650
2017-11-16T02:24:44.293
2017-11-16T02:24:44.293
2,582,339
2,582,339
[ "database", "authentication", "backend", "mobile-development" ]
47,720,655
1
null
null
4
1,001
I was struggling with using `AppCompatActivity` and `Activity` (and recently realized there is `ActivityCompat` even) and things like `Toolbar` vs `ActionBar` etc. it feels like things using `AppCompat` seem to be more stable. For example it works so much more smoothly with things like `PreferenceFragment`. On the other hand, as I understand the `AppCompat` is mostly for supporting devices below APIv21 which not even supported by security patches today. So, is there any reason to use `AppCompat` in a new application? What is the future of `AppCompat`? Is it a sliding window of versions or `AppCompat` will be phased off in future? Thanks!
Is there any reason to use AppCompat`?
CC BY-SA 3.0
null
2017-12-08T19:04:27.997
2017-12-08T19:04:27.997
null
null
2,870,834
[ "android", "android-appcompat", "mobile-development" ]
47,942,420
1
null
null
0
53
I am trying to change the text in text view cityName on itemclicked from the spinner but when i click on the item it does not does not change the text. I have tried it several times but it still not working what am i doing wrong here? I have tried using just position in arraylist.get[posistion] but it still does not change the text in cityName TextView ``` public class TimeMain extends AppCompatActivity { TextView cityName; ArrayList arrayList=new ArrayList<GetZones>(); Spinner mySpinner; @TargetApi(Build.VERSION_CODES.N) @Override protected void onCreate(Bundle savedInstanceState) { super.onCreate(savedInstanceState); setContentView(R.layout.activity_time_main); cityName=findViewById(R.id.cityName); mySpinner=(Spinner)findViewById(R.id.spinner); getCountryList(); Time_Converter_Adapter adapter=new Time_Converter_Adapter(arrayList,this); mySpinner.setAdapter(adapter); mySpinner.setOnItemSelectedListener(new AdapterView.OnItemSelectedListener() { @Override public void onItemSelected(AdapterView<?> parent, View view, int position, long id) { GetZones getZones; getZones= (GetZones) arrayList.get(parent.getSelectedItemPosition()); cityName.setText(getZones.getCountryName()); } @Override public void onNothingSelected(AdapterView<?> parent) { cityName.setText("Selected cities Name"); } } public void getCountryList() { RequestQueue requestQueue; requestQueue = Volley.newRequestQueue(getApplicationContext()); StringRequest stringRequest = new StringRequest(Request.Method.GET, "http://api.timezonedb.com/v2/list-time-zone?key=Z35J0I51CRWE&format=json", new Response.Listener<String>() { @Override public void onResponse(String response) { try { JSONObject res = new JSONObject(response); JSONArray jsonArray=res.getJSONArray("zones"); for(int i=0;i<jsonArray.length();i++) { JSONObject jsonObject=jsonArray.getJSONObject(i); String countryName=jsonObject.getString("countryName"); int timestamp=jsonObject.getInt("timestamp"); String countryCode=jsonObject.getString("countryCode"); GetZones getZones=new GetZones(countryName,countryCode,timestamp); arrayList.add(getZones); } } catch (JSONException e) { e.printStackTrace(); Toast.makeText(getApplicationContext(), "There Was A Fatal Error!!!!", Toast.LENGTH_SHORT).show(); } } }, new Response.ErrorListener() { @Override public void onErrorResponse(VolleyError error) { Context context = getApplicationContext(); if (error instanceof TimeoutError || error instanceof NoConnectionError) { Toast.makeText(context, "Connection Timed Out", Toast.LENGTH_LONG).show(); } else if (error instanceof AuthFailureError) { //TODO } else if (error instanceof ServerError) { //TODO } else if (error instanceof NetworkError) { //TODO } else if (error instanceof ParseError) { //TODO } } }); requestQueue.add(stringRequest); } ```
Can't Change text on itemclicklistener() spinner
CC BY-SA 3.0
null
2017-12-22T13:33:08.473
2017-12-22T14:05:05.823
2017-12-22T13:59:51.880
2,649,012
7,802,014
[ "java", "android", "mobile-development" ]
47,971,454
1
null
null
0
89
I am a junior Android Developer and I intend to develop a little cross platform with Xamarin. This app is just a FAQ with an enormous amount of data which will not change in the time (additionally I would like to add a quiz). I want the app be multilingual and be accessible without Internet Connection. My worry is about the choice of the method of storage of the data and the handling of translation. Which method should you recommend?
Data storage best practice mobile application
CC BY-SA 3.0
null
2017-12-25T19:26:28.867
2017-12-27T23:34:09.903
2017-12-27T23:34:09.903
472,495
9,138,205
[ "xamarin", "translation", "mobile-development" ]
47,977,432
1
null
null
-4
52
I am learning Android app development with Udacity. I have downloaded Android development kit but when I installed it ask for SDK setup. I have check on Youtube but there I can't find related video. Please any one could give a link for video or just point out me ways for installing it.
Android development kit SDK setup
CC BY-SA 3.0
null
2017-12-26T10:47:36.160
2017-12-26T14:24:35.867
2017-12-26T14:24:35.867
8,329,480
9,141,295
[ "android", "android-sdk-tools", "android-sdk-2.3", "mobile-development" ]
47,981,887
1
48,009,482
null
2
731
I decided to use `back4app` for easily creating my backend and for having a built in hosting solution. I'm quite a newbie with this tool so my question will seem "simple": I was wondering how will I store the images of my mobile application. As far as I know they use `AWS` so I thought the service would provide like an interface to upload some images to a S3 bucket... Should I create a personal bucket or does the service offer that kind of feature ? The idea is to store then the absolute url of the image in my model. For example each `Class` has a `cover` field of type `string`.
How to store images for mobile development
CC BY-SA 3.0
null
2017-12-26T17:37:45.830
2017-12-28T14:43:36.973
null
null
1,365,862
[ "amazon-s3", "mobile-development", "back4app" ]
48,020,977
1
null
null
0
386
I have a project using [chessboard.js](http://chessboardjs.com/) as well as some other libraries and all of them are using jQuery intensively. Now I am trying to reuse this code in mobile version using [Ionic Framework](https://ionicframework.com/). I understand that it is possible to use jQuery with Angular and Typescript, but many people argue that it is a bad decision to mix jQuery with Angular due to the slow DOM operations of jQuery. But to rewrite huge libraries from Jquery to Typescript on my own also seem to be a bad decision. So would it worth it to reuse jQuery code in Ionic 3 project or should I consider another options such as [Apache Cordova](https://cordova.apache.org/) which seem to be significantly lesser of suggested options?
Can I use jQuery library with Ionic 3?
CC BY-SA 3.0
null
2017-12-29T10:17:22.517
2017-12-29T10:17:22.517
null
null
3,523,475
[ "jquery", "cordova", "typescript", "ionic-framework", "mobile-development" ]
48,029,129
1
null
null
8
1,174
Images with spaces in their name won't load in IOS, for android it worked by replacing the spaces with %20, but this solution didn't work on ios. React native. I m loading the images remotely using uri, in a normal Image container. images without space load fine.
React native: images with space in name won't load in IOS (device, not https issue)
CC BY-SA 3.0
null
2017-12-29T22:31:48.867
2021-09-27T05:45:13.903
2017-12-29T22:39:14.657
2,287,471
2,287,471
[ "ios", "react-native", "mobile-development" ]
48,086,114
1
null
null
3
600
Has anyone used 'react-native-camera' component with re-natal? I am just trying out the react-native-camera component in the default re-natal skeleton project. My code is following ``` (ns wmshandheld.android.core (:require [reagent.core :as r :refer [atom]] [re-frame.core :refer [subscribe dispatch dispatch-sync]] [wmshandheld.events] [wmshandheld.subs])) (def ReactNative (js/require "react-native")) (def ReactNativeCamera (js/require "react-native-camera")) (def app-registry (.-AppRegistry ReactNative)) (def camera (.-Camera ReactNativeCamera)) (def text (r/adapt-react-class (.-Text ReactNative))) (def view (r/adapt-react-class (.-View ReactNative))) (def touchable-highlight (r/adapt-react-class (.-TouchableHighlight ReactNative))) (defn alert [title] (.alert (.-Alert ReactNative) title)) (defn app-root [] (fn [] [view {:style {:flex-direction "column" :margin 40 :align-items "center"}} [camera {:ref (fn [cam] (this-as this (set! (.-camera this) cam))) :style {:flex 1 :justify-content "flex-end" :align-items "center"} :aspect (.-fill (.-Aspect (.-constants camera)))} [text {:style {:flex 0 :background-color "#fff" :border-radius 5 :color "#000" :padding 10 :margin 40} :on-press #(alert "HELLO!")} "[CAPTURE]"]]])) (defn init [] (dispatch-sync [:initialize-db]) (.registerComponent app-registry "WMSHandheld" #(r/reactify-component app-root))) ``` But I got such an error. ``` console.error: "Error rendering component (in wmshandheld.android.core.app_root)" error YellowBox.js:71:16 finishClassComponent ReactNativeFiber-dev.js:1667:86 updateClassComponent ReactNativeFiber-dev.js:1659:33 beginWork ReactNativeFiber-dev.js:1786:44 performUnitOfWork ReactNativeFiber-dev.js:2528:33 workLoop ReactNativeFiber-dev.js:2554:141 _invokeGuardedCallback ReactNativeFiber-dev.js:73:23 invokeGuardedCallback ReactNativeFiber-dev.js:47:40 performWork ReactNativeFiber-dev.js:2593:41 scheduleUpdateImpl ReactNativeFiber-dev.js:2728:101 scheduleUpdate ReactNativeFiber-dev.js:2711:38 enqueueSetState ReactNativeFiber-dev.js:1514:90 setState react.development.js:218:31 <unknown> figwheel-bridge.js:88:33 waitForFinalEval figwheel-bridge.js:197:21 <unknown> figwheel-bridge.js:28:17 fireEvalListenters figwheel-bridge.js:27:41 <unknown> figwheel-bridge.js:118:24 tryCallOne core.js:37:14 <unknown> core.js:123:25 <unknown> JSTimers.js:301:23 _callTimer JSTimers.js:154:6 _callImmediatesPass JSTimers.js:202:17 callImmediates JSTimers.js:470:11 __callImmediates MessageQueue.js:278:4 <unknown> MessageQueue.js:145:6 __guard MessageQueue.js:265:6 flushedQueue MessageQueue.js:144:17 callFunctionReturnFlushedQueue MessageQueue.js:119:11 ``` Does anyone know what is the problem? and how to solve it? just a bare working example that uses react-native-camera on github or gist would be perfect!...
Using react-native-camera in ClojureScript re-natal development
CC BY-SA 3.0
null
2018-01-03T22:29:48.237
2018-12-12T06:01:36.573
null
null
5,802,173
[ "react-native", "clojure", "clojurescript", "mobile-development", "re-natal" ]
48,250,471
1
null
null
0
290
I'm a novice in Android Development, how do I combine different APIs in Microsoft azure cognitive services? specifically with Face, Computer Vision, and Emotion API. Here is what I came up with, I was able to display the simple description of the image. However, I am having a hard time merging the celebrity model to my project. Below is process method ``` private String process() throws VisionServiceException, IOException { Gson gson = new Gson(); String model = "celebrities"; //put image into an input stream for detection ByteArrayOutputStream output = new ByteArrayOutputStream(); bitmapPicture.compress(Bitmap.CompressFormat.JPEG, 100, output); ByteArrayInputStream inputStream = new ByteArrayInputStream(output.toByteArray()); AnalysisResult v = this.client.describe(inputStream, 1); AnalysisInDomainResult m = this.client.analyzeImageInDomain(inputStream,model); String result = gson.toJson(v); String result2 = gson.toJson(m); Map map = new HashMap(); map.put(result, result); map.put(result2, result2); return String.valueOf(map); } ``` Here is the onPostExecute()... ``` @Override protected void onPostExecute(String data) { super.onPostExecute(data); mEditText.setText(""); if (e != null) { mEditText.setText("Error: " + e.getMessage()); this.e = null; } else { Gson gson = new Gson(); AnalysisResult result = gson.fromJson(data, AnalysisResult.class); AnalysisInDomainResult result2 = gson.fromJson(data, AnalysisInDomainResult.class); //decode the returned result JsonArray detectedCelebs = result2.result.get("celebrities").getAsJsonArray(); if(result2.result != null){ mEditText.append("Celebrities detected: "+ detectedCelebs.size()+"\n"); for(JsonElement celebElement: detectedCelebs) { JsonObject celeb = celebElement.getAsJsonObject(); mEditText.append("Name: "+celeb.get("name").getAsString() +", score" + celeb.get("confidence").getAsString() +"\n"); } }else { for (Caption caption: result.description.captions) { mEditText.append("Your seeing " + caption.text + ", confidence: " + caption.confidence + "\n"); } mEditText.append("\n"); } /* for (String tag: result.description.tags) { mEditText.append("Tag: " + tag + "\n"); } mEditText.append("\n"); mEditText.append("\n--- Raw Data ---\n\n"); mEditText.append(data);*/ mEditText.setSelection(0); } } ``` Before I try to merge celebrity model to my project, it works fine :/ Now, whatever picture I took, it returns error on post execute.
How to combine different API from microsoft cognitive services
CC BY-SA 3.0
null
2018-01-14T14:18:35.850
2018-02-07T12:29:24.363
2018-02-07T12:29:24.363
9,215,847
9,215,847
[ "java", "android", "azure", "android-studio", "mobile-development" ]
48,321,305
1
48,321,557
null
0
538
I am trying to get a tab menu to appear using react-navigation (TabNavigator) but I either get the below red screen error or If I change the name of the keys I get a blank screen. I am using: ``` react-native: 0.51.0 npm: 4.6.1 ``` This is my router.js file: ``` import React from 'react'; import { TabNavigator } from 'react-navigation'; import { Icon } from 'react-native-elements'; import BooksList from '../screens/BooksList'; import FilmsList from '../screens/FilmsList'; export const Tabs = TabNavigator({ BooksList: { screen: BooksList, navigationOptions: { tabBar: { label: "Books", icon: ({ tintColor }) => <Icon name="list" size={35} color={tintColor} /> } } } }); ``` This is my BookList.js file: ``` import React, { Component } from 'react'; import { Text, View, ScrollView } from 'react-native'; import { List, ListItem } from 'react-native-elements'; import { users } from '../config/data'; import '../config/ReactotronConfig'; import Reactotron from "reactotron-react-native"; class BooksList extends Component { onLearnMore = user => { this.props.navigation.navigate("Details", { ...user }); }; render() { return ( <ScrollView> <List> {users.map(user => ( <ListItem key={user.login.username} roundAvatar avatar={{ uri: user.picture.thumbnail }} title={`${user.name.first.toUpperCase()} ${user.name.last.toUpperCase()}`} subtitle={user.email} onPress={() => this.onLearnMore(user)} /> ))} </List> </ScrollView> ); } } export default BooksList; ``` [](https://i.stack.imgur.com/uFfuo.jpg)
Tab Navigator - Error: Invalid Key 'tabBar' defined in navigation options
CC BY-SA 3.0
null
2018-01-18T12:24:26.970
2018-01-18T12:36:37.537
null
null
6,836,059
[ "react-native", "mobile-development", "react-native-navigation" ]
48,355,347
1
null
null
-1
1,006
I just downloaded java JDK 8 and set the environment variables for JDK and JRE, downloaded android SDK extracted them directly to C: (there were no platform tools so I used the command line to download them) and also set the environment variables. And I downloaded eclipse oxygen and I installed new software for ADT Plugin. When I set preferences I referred to the SDK folder and hit apply but nothing seems to happen like no SDK targets are listed. Hhuhuhuhuhuhuhu T^T I have deleted everything from Java, SDK, eclipse and downloaded them all again while disabling my antivirus but that didn't fix it. I also cant open my Android SDK Manager using eclipse, like it shows that it's loading but after that nothing happens even if I wait for 10 mins nothing shows up on screen, not even the command line that seems to just flash briefly which is what most people are having problems with when I search google. Can someone please tell me what to do?? I'm mainly using eclipse for android projects in school
How to set eclipse for android development?
CC BY-SA 3.0
null
2018-01-20T11:05:09.297
2018-01-20T12:11:55.130
2018-01-20T12:11:55.130
1,993,001
9,243,889
[ "java", "android", "eclipse", "mobile-development" ]
48,418,319
1
48,420,886
null
1
271
It seems like the code for animating a view's scale and translation is always much more clean and concise (e.g. using `.animate()`) than code that animates the view's LayoutParams (i.e. width, height, etc.) which requires the use of animators (`ValueAnimator`, `ObjectAnimator`, etc.) That made me wonder whether animating a certain view's LayoutParams is considered a bad practice, or if it's "heavier" than animating the view's translation and scale properties? Also, couldn't find any answers for this on SO so it would be great if anyone could shed some light on the subject.
Animating LayoutParams vs. Translation and Scale in Android
CC BY-SA 3.0
null
2018-01-24T08:53:24.483
2018-01-24T11:02:56.607
null
null
805,425
[ "java", "android", "animation", "kotlin", "mobile-development" ]
48,474,519
1
48,474,577
null
-1
200
Can an activity do an intent to itself? I have an activity created, it's called activity_beautician_profile. This activity has an edit button, which lets the user edit their profile. So I was planning on disabling the EditText at first and then enabling it when the user clicks the edit button. I added an android:onClick="onClick" in the edit button already ``` public class BeauticianProfile extends AppCompatActivity { Button btnedit; EditText t1, t2, t3; @Override protected void onCreate (Bundle savedInstanceState) { super.onCreate(savedInstanceState); setContentView(R.layout.activity_beautician_profile); final EditText t1 = (EditText) findViewById(R.id.name); final EditText t2 = (EditText) findViewById(R.id.address); final EditText t3 = (EditText) findViewById(R.id.email); final EditText t4 = (EditText) findViewById(R.id.gender); //so that i can pass my values from the sign-Up page to this page t1.setText(getIntent().getExtras().getString("name")); t2.setText(getIntent().getExtras().getString("mobile")); t3.setText(getIntent().getExtras().getString("email")); t4.setText(getIntent().getExtras().getString("gender")); } public void onClick (View v) { if (v.getId() == btnedit.getId()) { t1.setFocusable(true); t2.setFocusable(true); t3.setFocusable(true); } } } ``` My apps stops when i click the edit button
How to let an activity intent to itself?
CC BY-SA 3.0
null
2018-01-27T09:45:24.377
2018-01-27T09:54:23.810
2018-01-27T09:54:07.653
3,897,122
9,243,889
[ "java", "android", "android-intent", "mobile", "mobile-development" ]
48,521,334
1
null
null
1
70
Im making an android application that has text to speech and I want to be able to customize its speech rate. I already have a code for it but i dont know how to apply the speech rate to the whole application. Here's the settings that I've created for the application. THANKS IN ADVANCE! :D ``` public float getSpeechRate(){ int checkedRadioButton = this.radioRate.getCheckedRadioButtonId(); if (checkedRadioButton == R.id.rate_slow){ return 0.5f; } else if (checkedRadioButton == R.id.rate_normal){ return 1.0f; } else if(checkedRadioButton == R.id.rate_fast){ return 1.5f; } return 0; } public void setSpeechRate(){ float speechRate = this.getSpeechRate(); if(speechRate == 0.5f){ speakOut("This is a slow speech rate"); } else if(speechRate == 1.0f){ speakOut("This is a normal speech rate"); } else { speakOut("This is a fast speech rate"); } ``` This is how I invoke the text to speech ``` toSpeech = new TextToSpeech(getApplicationContext(), new TextToSpeech.OnInitListener() { @Override public void onInit(int status) { Log.e("TTS", "TextToSpeech.OnInit..."); } }); ```
How to apply the built in settings to the whole application
CC BY-SA 3.0
null
2018-01-30T12:19:43.007
2018-01-30T16:07:58.100
2018-01-30T12:39:14.540
9,215,847
9,215,847
[ "android", "text-to-speech", "mobile-development" ]
48,679,757
1
null
null
-1
652
I know this is very old question? but still i am looking for an answer. Is xamarin available for linux or not? If it is not available is there any alternate solution? I heard about mono development. Shall I use mono development for xamarin on linux. If yes, share with details. It'll be very helpfull.
Is there any way to create xamarin mobile applications on linux?
CC BY-SA 3.0
null
2018-02-08T07:21:11.723
2018-02-08T08:10:49.263
null
null
8,450,860
[ "android", "xamarin", "xamarin.forms", "mobile-development" ]
48,694,150
1
null
null
1
3,106
I've stuck on one issue with development react native app for android phone. I don't know why but a setting position with the absolute option doesn't work on Android and works on IOS. I need your help guys! Stackoverflow asks me to add more details but I don't know what details should here else - that's why this is the useless sentence here :). ``` <ScrollView> <View style={styles.container}> <View style={{width: '97%'}}> <FormLabel>Ship title</FormLabel> <FormInput containerStyle={styles.inputShipTitle}/> <Card title='Pickup Address' titleNumberOfLines={1} dividerStyle={{width: 0}}> <View> <Icon iconStyle={styles.iconPickup} name='map-marker' type='font-awesome' size={normalize(25)} /> <Text style={styles.additionalText}>Tap to select the pickup address</Text> </View> </Card> <Card title='Delivery Address' titleNumberOfLines={1} dividerStyle={{width: 0}}> <View> <Icon iconStyle={styles.iconTruck} name='truck' type='font-awesome' size={normalize(23)} /> <Text style={styles.additionalText}>Tap to select the delivery address</Text> </View> </Card> <Card title='Pickup date' titleNumberOfLines={1} dividerStyle={{width: 0}}> <View> <Icon iconStyle={styles.icon} name='calendar' type='font-awesome' size={normalize(23)} /> <Text style={styles.additionalText}>Tap to select the pickup date</Text> </View> </Card> <Card title='Pickup time' titleNumberOfLines={1} dividerStyle={{width: 0}}> <View> <Icon iconStyle={styles.icon} name='clock-o' type='font-awesome' size={normalize(23)} /> <Text style={styles.additionalText}>Tap to select the pickup time</Text> </View> </Card> <Card title='Add Photo or Video' titleNumberOfLines={1} dividerStyle={{width: 0}}> <View> <Icon iconStyle={styles.iconPhoto} name='camera' type='font-awesome' size={normalize(23)} /> </View> </Card> </View> </View> </ScrollView> ``` And styles : ``` const styles = StyleSheet.create({ container: { flex: 1, flexDirection: 'column', alignItems: 'center', justifyContent: 'space-between' }, inputShipTitle: { height: verticalScale(45), borderWidth: 1, borderStyle: 'solid', borderRadius: 3, }, icon: { position: 'absolute', left: moderateScale(5), bottom: moderateScale(5), }, iconPhoto: { position: 'absolute', left: moderateScale(5), bottom: moderateScale(5), }, iconPickup: { position: 'absolute', left: moderateScale(8), bottom: moderateScale(5), zIndex:1, }, iconTruck: { position: 'absolute', left: moderateScale(5), bottom: moderateScale(5), // right: width * 0.03, }, additionalText: { position: 'absolute', bottom: moderateScale(10), left: moderateScale(60,2), fontSize: normalize(7), color: 'grey', } }); ``` The 1st picture is IOS and the 2nd one is android. [](https://i.stack.imgur.com/0F1i9.png) [](https://i.stack.imgur.com/yikOB.png)
React native position absolute doesn't work
CC BY-SA 3.0
null
2018-02-08T20:21:13.987
2018-02-09T09:10:33.273
2018-02-09T09:10:33.273
4,443,323
7,863,095
[ "javascript", "android", "reactjs", "react-native", "mobile-development" ]
48,718,086
1
48,721,932
null
1
732
I have a navigation bar and a collection view programmatically added to my app and I am trying to add in a custom view as well. I have gotten the view to sit above the collection view and beneath the navigation bar, which is what I want, however, on iOS 11, the navigation bar has a changing height depending on if you stretch the collection view down. I would like to make the view move downwards as well so that there is not a gaping white space between the collection view and the navigation bar, as my custom view does not move downwards further since the view's safeInsets do not change. It will move upwards towards the collapsing title and that is not an issue. ``` override func viewDidLoad() { super.viewDidLoad() navigationItem.title = "Home" navigationController?.navigationBar.prefersLargeTitles = true collectionView?.backgroundColor = UIColor.white collectionView?.translatesAutoresizingMaskIntoConstraints = false //collectionView?.contentInset = UIEdgeInsets(top: 50, left: 0, bottom: 0, right: 0) //collectionView?.scrollIndicatorInsets = UIEdgeInsets(top: 50, left: 0, bottom: 0, right: 0) collectionView?.register(StockCell.self, forCellWithReuseIdentifier: "cellid") setupMenuBar() } let menuBar: MenuBar = { let mb = MenuBar() mb.translatesAutoresizingMaskIntoConstraints = false mb.backgroundColor = .black return mb }() private func setupMenuBar() { view.addSubview(menuBar) NSLayoutConstraint.activate([ (collectionView?.topAnchor.constraint(equalTo: menuBar.bottomAnchor))!, (collectionView?.widthAnchor.constraint(equalTo: view.widthAnchor))!, (collectionView?.bottomAnchor.constraint(equalTo: view.bottomAnchor))!, menuBar.heightAnchor.constraint(equalToConstant: 50), menuBar.widthAnchor.constraint(equalTo: view.widthAnchor, multiplier: 1), menuBar.topAnchor.constraint(equalTo: view.safeAreaLayoutGuide.topAnchor) ]) } ``` [This is the starting screen, showing the view in its resting position](https://i.stack.imgur.com/lAF8B.png) [This is the navigation bar overlapping the view, which is what I want to fix](https://i.stack.imgur.com/Eqt9O.png)
How to pin a UIView underneath the iOS 11 NavigationBar's changing height frame?
CC BY-SA 3.0
null
2018-02-10T06:51:33.030
2018-02-10T14:42:21.547
null
null
9,192,045
[ "ios", "iphone", "swift", "ios11", "mobile-development" ]
48,765,235
1
null
null
4
1,689
I know that it is not really going to help me out, but still I have some doubts related to "CTGetSignalStrength()" method of Core Telephony framework. What I know about this method is: 1. It is an undocumented method. 2. It belongs to a Private API. 3. If I use this method, App store will reject my application. 4. Also, I read that there is no public API to get the Signal Strength in iOS. My reason to pick this topic up again because all the other answers are atleast 2 years old. And also, I have seen some applications on App store which really tells about the cellular/Wifi Strength(Like Dr.Wifi-something). If its not possible to get the signal Strength, how those applications are getting it? Or there is some other way now through which we can get the network Strength. I would really appreciate if someone can enlighten me on this. Thank you. : I have checked that question before, the one in the comment, but please see that : 1. The answer is really old. 2. In the comments, you can see someone asked "How OpenSignal is doing there signal strength measurement?" and there is no reply to that. 3. Every opportunity to get signal strength is either removed in the updated iOS version, or giving null or 0 as output. So I am not really sure if there is no solution present for the problem or, the solution is not yet updated to that question.
xcode - Network Strength in iOS
CC BY-SA 3.0
0
2018-02-13T11:00:06.963
2018-02-13T12:25:42.520
2018-02-13T12:08:01.577
5,319,831
5,319,831
[ "ios", "objective-c", "iphone", "core-telephony", "mobile-development" ]
49,092,441
1
null
null
5
403
I am relatively new to web development, and am currently building an Ionic/angular2 hybrid mobile app. I have used the in browser devtools just fine until now. When I am using the mobile device testing screen, the browser registers a right-click whenever I click/press and hold. It only happens when I click and hold within the device testing viewport, not outside of the device view. Because of this I thought it might be an issue in the app code, but the right-click menu that appears is the one from my computer, not what would be a secondary tap on a mobile device. It happens in both the updated firefox and chrome devtools, and I cannot find any setting for it. I have a macbook pro and have adjusted all of my trackpad/mouse settings to no avail. This is greatly hindering my testing as I have a press and hold feature in my app, yet I cannot test it because when the right click is registered, my app screen fails to record a mouseup event. This is my first question asked on here so go easy please haha, and thanks for the help!
Unwanted right-click with in browser DevTools
CC BY-SA 3.0
null
2018-03-04T05:53:34.423
2021-03-07T00:48:09.440
null
null
9,440,543
[ "angular", "firefox", "ionic2", "google-chrome-devtools", "mobile-development" ]
49,108,011
1
49,108,445
null
2
1,345
I'm uncertain if this is the right place to raise this question, please let me know if not and I'll take it down. We have outsourced the development of an app for our company on iOS and Android. The UAT has been signed off on and the app is currently live. We are now finalising the project and they are giving us the code and such. In general what list of documents or specific bits (API Keys, Logins) would we need to obtain from them to conclude this?
App Development: Project Finalisation & Handover (iOS & Android)
CC BY-SA 3.0
null
2018-03-05T10:14:48.193
2018-03-06T09:22:58.680
null
null
9,359,733
[ "android", "ios", "mobile", "mobile-development" ]
49,156,982
1
null
null
-14
719
So I want to build a small native mobile app using Vuejs. I understand that there are two platforms on which you can develop native mobile apps using VueJs; Weex and Nativescript. Here are my questions: 1- Have you worked with any of the platforms? If yes, are they any good? (I've heard bad reviews so far) 2-According to my research React Native is way better than both platforms so I was curios to know if anyone here has worked with ''? React-Vue: [https://github.com/SmallComfort/react-vue](https://github.com/SmallComfort/react-vue) 3- Should I abandon my VueJs background and go for Reactjs and React Native? Thanks
Is there a good VueJs native mobile platform?
CC BY-SA 3.0
0
2018-03-07T16:36:47.233
2018-03-07T19:49:12.943
null
null
5,619,967
[ "angularjs", "web-deployment", "nativescript", "mobile-development", "weex" ]
49,181,391
1
49,182,098
null
0
205
I am trying to run a shell command from my application directory and I am getting "working directory null and environment null. I have looked at several posts here but I'm not quite sure where to go from here. Error: Error running exec(). Command: [/data/user/0/com.netscout.iperf3_clientls] Working Directory: null Environment: null ``` public void startApp() { StringBuffer output = new StringBuffer(); Process process = null; String appFileDir = getApplicationInfo().dataDir; // String commandLine = appFileDir + "/iperf3 -c 129.196.197.116 --forceflush -O3 -Z -P2"; String commandLine = appFileDir + "ls"; try { process = Runtime.getRuntime().exec(commandLine, null, null); BufferedReader reader = new BufferedReader(new InputStreamReader(process.getInputStream())); String line = ""; while ((line = reader.readLine())!= null) { // output.append(line + "/n"); Log.e("Line", String.valueOf(line)); Log.e("output", String.valueOf(output)); } } catch (IOException e) { e.printStackTrace(); Log.i("Output", String.valueOf(e)); } } ```
Java.io.Exception: Working Directory: null Environment: null
CC BY-SA 3.0
null
2018-03-08T19:52:45.430
2018-03-08T20:43:03.807
null
null
2,833,197
[ "java", "android", "android-studio", "mobile-development" ]
49,189,003
1
49,195,436
null
2
2,223
- - [http://192.168.4.1/?pin=13](http://192.168.4.1/?pin=13)- Then a function call on Web is used and a GET request is send.- I wanted to ask how to implement the same functionality using Android Studio. Maybe a name of component or function in Java Code.- I am attaching the block design for reference. [](https://i.stack.imgur.com/x0UFc.png)
How do I use Web Component of MIT App Inventor in Android Studio?
CC BY-SA 3.0
null
2018-03-09T07:52:04.913
2018-03-10T16:17:49.610
2018-03-10T16:17:49.610
1,545,993
7,897,413
[ "android", "app-inventor", "mobile-development" ]
49,196,906
1
49,211,022
null
0
218
This is more of a design question, i'm building a NativeScript mobile application where users are restricted by a number of requests per day. After they login or start the application and I check: ``` public ngOnInit() { MAX_TRIES = 1000 if(ApplicationSettings.getBoolean("authenticated", false){ if(ApplicationSettings.getNumber("requests", MAX_TRIES) != MAX_TRIES){ // Then continue, allow user to proceed } } ``` However coming from using Flask you'd typically want to keep these variables (attempts, wins/losses) in a server side database, however if you're simply storing a key `authenticated` inside ApplicationSettings then i'm guessing it's okay to keep every user variable stored locally? Or should I avoid ApplicationSettings and just make everything in my application a REST Request?
Security of Nativescript ApplicationSettings vs REST API
CC BY-SA 3.0
null
2018-03-09T15:21:01.823
2018-03-10T15:52:33.440
null
null
5,660,197
[ "nativescript", "mobile-development" ]
49,252,912
1
null
null
2
39
I am currently developing an app for visually impaired users and it have been requested that we reduce the amount of alerts from the OS's notification centres that appear during its use. Is this even possible? I ask as I believe all apps are sandboxed these days to prevent you playing with core OS systems. I have done some Googling and found plenty about registering to the Apple Push Notification service and being able to handle your own messages, but nothing about silencing them all temporarily. The only possible advice I have is Do Not Disturb, but that's a terrible idea! Any ideas? Thanks
How to silence Android/iOS notifications during app use?
CC BY-SA 3.0
null
2018-03-13T09:47:41.870
2018-03-13T09:47:41.870
null
null
1,555,828
[ "android", "ios", "push-notification", "notifications", "mobile-development" ]
49,300,414
1
null
null
-1
145
I'm using AngularJS, Ionic and Cordova to create a project and my question is pretty straight forward: How to show element, like div, during some time period(e.g. 8:00 15.2.2018. - 20:00 15.2.2018.), otherwise hide it? EDIT: This is what I got for now: ``` (function() { 'use strict'; angular .module('module-name') .directive('timeRestricted', timeRestricted); timeRestricted.$inject = [ '$timeout' ] function timeRestricted($timeout) { var directive = { link: link, restrict: 'A' }; return directive; function link(scope, element, attrs, ctrl) { var startTime = Date.parse(attrs.startTime); var endTime = Date.parse(attrs.endTime); var currentTime = new Date(); var showTimeoutId = $timeout( function() { console.log(`show: ${JSON.stringify(element)}`); element.show(); }, currentTime - startTime ) var hideTimeoutId = $timeout( function() { console.log(`hide: ${JSON.stringify(element)}`); element.hide(); }, endTime - startTime ) element.on('$destroy', function() { $interval.cancel(showTimeoutId); $interval.cancel(hideTimeoutId); $interval.cancel(updateTimeoutId); }); } } })(); ``` Now I get `Error: element.hide is not a function` and same for `element.show`. I saw couple of examples showing similar usage of these functions and element in my example is a div tag which I use like this: ``` <div time-restricted start-time={{vm.startTime}} end-time={{vm.endTime}> </div> ```
Show element during some time period, otherwise hide it
CC BY-SA 3.0
null
2018-03-15T13:13:34.147
2018-03-15T15:36:20.857
2018-03-15T15:36:20.857
6,619,676
6,619,676
[ "angularjs", "cordova", "ionic-framework", "web", "mobile-development" ]
49,411,279
1
49,552,870
null
0
124
although I specifically mention AngularJS, Ionic and Cordova here, I'm really talking about mobile app (hybrid and native alike) that produces binaries for iOS and Android platforms. As such, I believe that anybody with experience in mobile dev should be able to address the question! --- I am building a mobile app for iOS and Android using AngularJS, Ionic and Cordova. My concern is that iOS and Android release updates all the time, some may be buggy or just might be outright breaking changes and all of the sudden become incompatible with the plugin/library versions that I'm using. This will cause apps to crash spontaneously in production. But it sheds light on an even nastier problem under the hood: making the decision to pin your builds against specific dependency (plugins/libraries/etc.) versions just always pull in the latest/stable versions of them! ### Option 1: Pin your dependency versions Here we specify the exact version of dependencies to use. We then fight with the Ionic build to get the app built, but are now good to go. I can expect that if I don't change any of my code, that each subsequent build of the app against the exact same dependency versions will always result with a successful build. , when iOS/Android release a breaking change or bug (or anything that prompts the library/plugin maintainers to go into a frenzy and publish new versions of themselves), because I've pinned my previous build to specific versions of dependencies, I may actually be running on very old dependency versions and it will now be a massive headache to get my app building again against all the latest versions. ### Option 2: Use latest/stable versions at all times If I specify dependency versions (and just let the build always use latest and greatest), then I could work fervently to get my app building, then wait a few days (and not change any of my own code) and then try building it again and the compile/build might fail! This is because in between those few days, some project upgraded itself and/or its own dependencies and introduced a build-breaking change. , when iOS/Android releases a breaking change that requires me to upgrade to latest dependencies, the headache would likely be considerably less then Option 1 since I'll be on a relatively much newer version of all my dependencies.
Stabilization techniques for mobile builds?
CC BY-SA 3.0
null
2018-03-21T16:07:26.813
2018-03-29T09:46:38.897
null
null
4,009,451
[ "android", "ios", "build", "mobile-development" ]
49,495,293
1
49,495,384
null
2
4,115
Background: I am working on a mobile application in which I use a WebViewScaffold to load an online directory. This particular directory provides a guided tour on initial visit. Problem: Each time I navigate to the directory WebView, the tour starts from the beginning (which freezes the user until the tour is finished). How might I keep this from happening? When I open the directory in a browser, the status of the tour is saved in the browser's local storage variables. Is there a way to save or reset the local storage variables in flutter? Code: Upon button click, I push a new route where I create a new Directory object which is shown below: ``` class MobileDirectory extends StatelessWidget { final _mobileDirectory = 'my.mobileDirectory.url'; final _directoryTitle = new Text( 'Directory', style: const TextStyle( fontSize: 17.0, color: Colors.white, fontWeight: FontWeight.w400), ); final _backgroundColor = new Color.fromRGBO(29, 140, 186, 1.0); final _backButton = new BackButton(color: Colors.white); final _padding = new EdgeInsets.only(left: 2.0); final _imageAsset = new Image.asset('assets/appBar.jpg'); @override Widget build(BuildContext context) { return new WebviewScaffold( appBar: new AppBar( leading: _backButton, centerTitle: true, backgroundColor: _backgroundColor, title: new Padding( padding: _padding, child: _directoryTitle, ), actions: <Widget>[ _imageAsset, ], ), url: _mobileDirectory, ); } } ``` Note: Please let me know if more information should be provided.
Flutter WebView Plugin - How To Handle Local Storage Variables
CC BY-SA 3.0
null
2018-03-26T15:34:15.770
2018-06-22T09:07:33.037
null
null
9,531,211
[ "dart", "flutter", "mobile-development" ]
49,499,469
1
null
null
0
36
Hi I am building a hybrid mobile app and wish to use this color for an alert. However, I cannot seem to get the color right along with the opacity. Does anyone know how to achieve this extremely subtle blur/transparency of this volume alert background? Thanks! ![screenshot with volume alert](https://i.stack.imgur.com/hvuMU.png)
Does anyone know this stock iOS color?
CC BY-SA 3.0
null
2018-03-26T19:47:49.313
2018-03-26T19:55:22.987
2018-03-26T19:55:22.987
2,887,133
9,440,543
[ "ios", "hybrid-mobile-app", "mobile-development" ]
49,508,679
1
null
null
2
74
[](https://i.stack.imgur.com/IpcQ6.png) [](https://i.stack.imgur.com/ZQNvH.png) Is it recommended to place a button next to the home button like Apple did it in the system weather app? I would suggest that in this area you should not place any control elements. I didn't find any Information about that topic in Apples iOS Interface Guidlines. (And why are the paging-dots in different positions from time to time?)
Is it recommended to place a button next to iPhone X virtual home button?
CC BY-SA 3.0
null
2018-03-27T09:06:48.100
2018-03-27T09:58:56.357
null
null
7,123,813
[ "ios", "user-interface", "ios11", "iphone-x", "mobile-development" ]
49,521,531
1
null
null
1
2,091
Background: I am opening a website in my flutter app using a WebViewScaffold ([flutter webview plugin](https://pub.dartlang.org/packages/flutter_webview_plugin)). The website has a option where you click a button and it launches the "tel://1231231234" url. Problem: The WebView displays , etc. (Similar to the problem shown [here](http://mariusbancila.ro/blog/2015/09/17/fix-err_unknown_url_scheme-on-android-webview-for-telsmsgeoetc-links/)). I need this to work on both iOS and Android. How can I make this happen using the Flutter WebView Plugin on both device platforms? I have seen several people who use intents (like the problem shown above) for Android only and are not using flutter. Is this a problem for platform specific code?
Flutter - Phone Call From Webpage Displayed in a WebViewScaffold
CC BY-SA 3.0
0
2018-03-27T20:02:41.417
2022-03-12T06:38:47.080
2018-03-28T14:49:11.237
8,581,389
9,531,211
[ "dart", "flutter", "mobile-development" ]
49,564,415
1
null
null
0
306
I have made a transparent background tabbar on my ionic/angular app. I have the following code in my app.scss ``` .tabbar { background: transparent !important; border: none !important; } .tabs-ios .tabbar { background: transparent !important; border: none !important; } .ion-tabs { background: transparent !important; border: none !important; } ``` It works fine when I test in the browser, but when I test with ionic view app, there is still a stock tabbar showing on the first page loaded by tabs page. Tabs are transparent on every other page, except the first one that is the "home" page. Does anyone know why this is? Is this just a bug in the exceptionally unreliable Ionic View app or a problem I should be trying to fix?
Ionic tabbar not transparent on root page
CC BY-SA 3.0
null
2018-03-29T20:22:38.527
2018-03-29T20:22:38.527
null
null
9,440,543
[ "angularjs", "ionic-framework", "mobile-development" ]
49,598,534
1
null
null
0
1,434
Can someone help me with setting up AppIcon in the application which was generated with create-react-native-app. There is no any native code. P.S. AppIcon is the main icon which you tap to start the app.
AppIcon React Native
CC BY-SA 3.0
null
2018-04-01T13:23:22.870
2018-04-01T13:49:06.830
null
null
7,863,095
[ "android", "ios", "reactjs", "react-native", "mobile-development" ]
49,621,332
1
null
null
0
190
Everything is fine when I am using a real Android device to run Xamarin Live Player. However, when I start Xamarin Live Player in an AVD. It just start with paired status and I cannot do anything to scan the qrcode or enter the pair code. Anyone can help? [](https://i.stack.imgur.com/Fu1Jp.png)
How come my AVD Xamarin Live Player always shows "Paired with Visual Studio"?
CC BY-SA 3.0
null
2018-04-03T02:28:44.183
2018-04-03T03:06:13.610
null
null
6,201,547
[ "visual-studio", "xamarin", "xamarin.android", "android-virtual-device", "mobile-development" ]
49,681,101
1
null
null
-1
40
I have problem with interaction within my view that was loaded programatically. When app’s running the view is displayed well, however all input fields are not responsible. Here is code of my view(file's owner - CarView): ``` CarView.swift - @IBDesignable class CarView: UIView { @IBOutlet var myView: UIView! override init(frame: CGRect) { super.init(frame: frame) commonInit() } required init?(coder aDecoder: NSCoder) { super.init(coder: aDecoder) commonInit() } private func commonInit(){ Bundle.main.loadNibNamed("CarView", owner: self, options: nil) self.bounds = self.myView.bounds myView.autoresizingMask = [.flexibleWidth, .flexibleHeight] addSubview(myView) } } ``` --- ``` var carView : CarView = CarView() @IBAction func carViewButton(_ sender: Any) { view.addSubview(carView) carView.translatesAutoresizingMaskIntoConstraints = false carView.topAnchor.constraint(equalTo: carButton.bottomAnchor, constant: 10).isActive = true carView.rightAnchor.constraint(equalTo: view.rightAnchor, constant: 8).isActive = true carView.leftAnchor.constraint(equalTo: view.leftAnchor, constant: 8).isActive = true } ```
IOS - user interaction does not work in view loaded from Xib
CC BY-SA 3.0
null
2018-04-05T20:36:50.447
2018-04-05T21:53:52.860
null
null
8,709,654
[ "ios", "swift", "mobile-development" ]
49,764,065
1
49,766,745
null
0
476
I'm developing a game in Unity. I want it to be similar to Jackbox Games in the way that the main game is ran on a computer attached to a TV in a living room, but the interaction from those playing it come from using their phone's mobile browser to send their input. The difference that I want to accomplish is I want it to be semi-real time. Think Mario-Party mini game real time, where you might have to spam a button or do some light movement left, right, up, or down. So here is the question: What is the best API for making the networking portion happen? I've looked into Unity Multiplayer, but it seems un-scaleable. Websockets seems possible, and Photon looks enticing with the Unity integration. I'm looking to eventually publish this, so it can't be a short-term solution. Thoughts? I'm open to any suggestions.
Unity + Mobile browser controller. Thoughts?
CC BY-SA 3.0
null
2018-04-10T23:05:01.887
2018-04-11T04:54:22.593
null
null
6,371,464
[ "user-interface", "unity3d", "networking", "mobile-development" ]