コード例 #1
0
        public AndroidApplicationContext(BaseScreen baseActivity, Settings settings, Action loadComplete)
        {
            ApplicationBackground += () => { };
            ApplicationRestore    += () => { };

            GlobalVariables = new Dictionary <string, object>();

            _baseActivity = baseActivity;
            _settings     = settings;
            _loadComplete = loadComplete;

            LocationProvider          = new GpsProvider(_baseActivity);
            LocationTracker           = new GpsTracker(_baseActivity);
            GalleryProvider           = new GalleryProvider(_baseActivity, this);
            CameraProvider            = new CameraProvider(_baseActivity, this);
            DialogProvider            = new DialogProvider(_baseActivity, this);
            DisplayProvider           = new DisplayProvider();
            ClipboardProvider         = new ClipboardProvider(_baseActivity);
            EmailProvider             = new EmailProvider(_settings, _baseActivity);
            JokeProviderInternal      = new JokeProvider(_baseActivity);
            LocalNotificationProvider = new LocalNotificationProvider(_baseActivity);
            WebProvider = new WebProvider(_baseActivity);

            var builder = new SolutionBuilder(this);

            builder.Build();

            _commonData = ValueStackContext.Current.CreateCommonData("Android");
        }
コード例 #2
0
        public void CopyText(int startPos, int endPos)
        {
            if (ClipboardProvider == null)
            {
                return;
            }

            ClipboardProvider.Copy(startPos, endPos);
        }
コード例 #3
0
        public void CutText(int startPos, int endPos)
        {
            if (ClipboardProvider == null || !Editable)
            {
                return;
            }

            ClipboardProvider.Copy(startPos, endPos);
            DeleteText(startPos, endPos);
        }
コード例 #4
0
        public void PasteText(int position)
        {
            if (ClipboardProvider == null || !Editable)
            {
                return;
            }

            try {
                ClipboardProvider.Paste(position);
            } catch (ElementNotEnabledException e) {
                Log.Debug(e);
            }
        }
コード例 #5
0
        public ApplicationContext(BaseScreen baseActivity, Settings settings, System.Action loadComplete)
        {
            GlobalVariables = new Dictionary <string, object>();

            _baseActivity = baseActivity;
            _settings     = settings;
            _loadComplete = loadComplete;

            LocationProvider = new GpsProvider(baseActivity);

            LocationTracker = new GPSTracker(baseActivity);

            GalleryProvider = new GalleryProvider(baseActivity);

            CameraProvider = new CameraProvider(baseActivity, this);

            DialogProvider = new DialogProvider(baseActivity, this);

            ClipboardProvider = new ClipboardProvider(baseActivity, this);

            Application.ApplicationContext.InitContext(this);
        }
コード例 #6
0
 public void Include(ClipboardProvider vm)
 {
     var vm1 = new ClipboardProvider();
 }