mvvmcross

Open MvvmCross app via link with data

一笑奈何 提交于 2019-12-11 00:22:48
问题 In native Android apps you can define an intent-filter for an activity in the Manifest file which can open the app when a specific link (e.g. myprotocol://mysite.com/action/data ) is visited from a website or email. <intent-filter> <data android:scheme="myprotocol" android:host="mysite.com"/> <action android:name="android.intent.action.VIEW"/> <category android:name="android.intent.category.DEFAULT" /> <category android:name="android.intent.category.BROWSABLE" /> </intent-filter> When I try

Unable run ProgressDialog - BadTokenException while showind

半城伤御伤魂 提交于 2019-12-11 00:20:04
问题 I am having a problem with a ProgressDialog thing in MVVMCross. I am getting Android.Views.WindowManagerBadTokenException : while creating ProgressDialog via IReportService where I have context from setup.cs. public class Setup : MvxBaseAndroidBindingSetup { public Setup(Context applicationContext) : base(applicationContext) { } protected override MvxApplication CreateApp() { return new NoSplashScreenApp(); } public class Converters { public readonly MvxVisibilityConverter Visibility = new

Binding 'GO' key on Software Keyboard

帅比萌擦擦* 提交于 2019-12-10 22:08:08
问题 I've got a log-in button bound to a command that exists inside my ViewModel like so: this.AddBindings(new Dictionary<object, string>{{btnLogin,"TouchUpInside LoginCommand"}}); The software keyboard is suppressed if a touch is made, somewhere outside the keyboard or UITextField . To prevent the user from having to click once somewhere on the screen to make the keyboard disappear and then pressing the log-in button, I would like to associate the log-in command defined in the ViewModel to the

Getting Messege Twice Using IMvxMessenger

断了今生、忘了曾经 提交于 2019-12-10 18:55:28
问题 I am working on Xamrin Android Application and I am using MvvmCross.In my application I have used IMvxMessenger.But I am getting messsge twice when I change the view and comeback to same view.And then It is Crashed. What is the solution ? Here is my code : In ViewModel I have this code : var messanger = Mvx.Resolve<IMvxMessenger>(); var message = new MyMessage(this,"Product has been added",cartListCount); messanger.Publish(message); And On View I have this code: private MvxSubscriptionToken

MvvmCross Custom Event Binding Event Args

白昼怎懂夜的黑 提交于 2019-12-10 18:49:07
问题 I have created a custom binding for the FocusChange event on an EditText using MvvmCross. I can get the event bound and firing, but I can't figure out how to pass the event args. My Custom Binding is this using Android.Views; using Android.Widget; using Cirrious.MvvmCross.Binding; using Cirrious.MvvmCross.Binding.Droid.Target; using Cirrious.MvvmCross.Binding.Droid.Views; using Cirrious.MvvmCross.ViewModels; using System; namespace MPS_Mobile_Driver.Droid.Bindings { public class

Resolve "'NSUnknownKeyException', reason:This class is not key value coding-compliant for the key X” exception

|▌冷眼眸甩不掉的悲伤 提交于 2019-12-10 18:29:32
问题 I am experience the exact same issue as identified in this submission: MvvmCross/Xamarin "This class is not key value coding-compliant for the key" The issue stems from trying to use MVVMCross databinding in an IOS CollectionView That article was closed and marked as a duplicate but I don't see it as such. The article that it links to as the solution offers workarounds when using XCode as a development environment. My scenario and the scenario described in the issue linked above are in using

Has MvxCachingFragmentCompatActivity disappeared?

只愿长相守 提交于 2019-12-10 18:25:49
问题 I'm trying to upgrade to MvvmCross 5.2 and get a syntax error on the MvxCachingFragmentCompatActivity. Has this class disappeared? 回答1: As explained in the blog for 5.2: https://www.mvvmcross.com/mvvmcross-52-release/ We've refactored the Android presenter and there is no need anymore for a special Activity like MvxCachingFragmentCompatActivity . The adviced Activity to use now is the MvxAppCompatActivity . 来源: https://stackoverflow.com/questions/46338395/has-mvxcachingfragmentcompatactivity

Random System.ArgumentException: 'jobject' must not be IntPtr.Zero

痴心易碎 提交于 2019-12-10 17:31:54
问题 We have random System.ArgumentException with Xamarin on android. It is completely random - it can occur anytime and anywhere, on any platform. We registered it on 5.1, 5.0, 4.4.4. It has no adequate stacktrace, it has no place where it thrown, I can't catch it with anything. I think it might be somehow related to async void , we use MVVMCross in the project and there are many async void Init and async void DoMvxCommand methods. But all of them enclosed in try-catch blocks. I crucially need

MvvmCross sidebar navigation for MvvmCross 5.x

谁说我不能喝 提交于 2019-12-10 17:14:56
问题 I with to implement two types of navigation for my app, sidebar navigation and parent-child navigation at the same time. My app starts with hamburger (sidebar) menu. First item in sidebar menu should perform reset of the navigation stack and open home view. Home view controller should start a root stack navigation so every button on the home view should open a new view, button on a new view should open another view etc. Every other item in sidebar menu should open a new view as a dialog. I'm

MVVMCross programmatically change start ViewModel

淺唱寂寞╮ 提交于 2019-12-10 17:14:20
问题 The portable class library defines the start view model. This scenario generally sounds great but I was considering this. You have written a iOS universal application or Android that needs to change its start screen / view model. If application is a phone, the default view model is login but if it is tablet, you want a different view model as the start. Is there an override or a way to take control of this? 回答1: See the Wiki section - https://github.com/MvvmCross/MvvmCross/wiki/Customising