Exemplo n.º 1
0
 public void OnPointerUp(PointerEventData pointer)
 {
     Clicked?.Invoke(this);
 }
 public void doDownloadId(string id)
 {
     Log.Debug("_____updater.doDownloadId({0})", id);
     Clicked?.Invoke(id);
 }
Exemplo n.º 3
0
 public void Fire()
 {
     Clicked?.Invoke(this, EventArgs.Empty);
 }
Exemplo n.º 4
0
 private void OnButtonTapped(object sender, EventArgs e)
 {
     Clicked?.Invoke(this, EventArgs.Empty);
 }
Exemplo n.º 5
0
 private void Button_Clicked(object sender, EventArgs e)
 {
     DLoggerManager.Instance.Logger.Log(devoctomy.DFramework.Logging.Interfaces.LoggerMessageType.VerboseMed | devoctomy.DFramework.Logging.Interfaces.LoggerMessageType.Information, "Tab button '{0}' clicked.", Text);
     IsPressed = true;
     Clicked?.Invoke(this, EventArgs.Empty);
 }
Exemplo n.º 6
0
 protected override void OnPointerUp()
 {
     Clicked?.Invoke(this);
 }
Exemplo n.º 7
0
 protected virtual void OnClicked(EventArgs e)
 {
     Clicked?.Invoke(this, e);
 }
Exemplo n.º 8
0
Arquivo: Button.cs Projeto: hevey/maui
 void IButtonElement.PropagateUpClicked() => Clicked?.Invoke(this, EventArgs.Empty);
 /// <summary>
 /// To broadcast a click event to subscribers
 /// </summary>
 public void SendClicked()
 {
     Clicked?.Invoke(this, EventArgs.Empty);
 }
Exemplo n.º 10
0
 private new void MouseClick(object sender, MouseEventArgs e)
 {
     Clicked?.Invoke(this, e);
 }
Exemplo n.º 11
0
 protected Task ClickHandler()
 {
     return(Clicked.InvokeAsync(null));
 }
Exemplo n.º 12
0
 protected void ClickHandler()
 {
     Clicked?.Invoke();
     ParentTabs?.SelectTab(Name);
 }
 public void ExportXML(Clicked click, String path)
 {
     System.IO.StreamWriter stream;
     XmlSerializer ser;
     switch (click)
     {
         case (Clicked.Jedis):
             stream = new System.IO.StreamWriter(@path + "\\ListeJedis.txt");
             ser = new XmlSerializer(typeof(List<Jedi>));
             ser.Serialize(stream, data.getAllJedi());
             stream.Close();
             break;
         case (Clicked.Stades):
             stream = new System.IO.StreamWriter(@path + "\\ListeStades.txt");
             ser = new XmlSerializer(typeof(List<Stade>));
             ser.Serialize(stream, data.getAllStade());
             stream.Close();
             break;
         case (Clicked.Matchs):
             stream = new System.IO.StreamWriter(@path + "\\ListeMatchs.txt");
             ser = new XmlSerializer(typeof(List<Match>));
             ser.Serialize(stream, data.getAllMatch());
             stream.Close();
             break;
         case (Clicked.Caracteristiques):
             stream = new System.IO.StreamWriter(@path + "\\ListeCaracteristiques.txt");
             ser = new XmlSerializer(typeof(List<Caracteristique>));
             ser.Serialize(stream, data.getAllCaracteristic());
             stream.Close();
             break;
         default:
             break;
     }
 }
Exemplo n.º 14
0
 /////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////
 public static void ShowNow(int identifier, string caption, string message, Type type, string button1Text, string button2Text, Clicked clicked)
 {
     Show(identifier, caption, message, type, button1Text, button2Text, clicked);
     mAlpha.Value = 1;
     mState = States.Running;
     mYesButton.enable = true;
     mNoButton.enable = true;
 }
Exemplo n.º 15
0
 protected void SendNavigationEvent(NavigationType navigationType)
 {
     Clicked.SafeRaise(navigationType);
 }
Exemplo n.º 16
0
 private void OnTabClicked(Tab tab)
 {
     Clicked?.Invoke(this);
 }
Exemplo n.º 17
0
 /////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////
 public static void Show(int identifier, string caption, string message, Type type, string button1Text, string button2Text, Clicked clicked, ThreadStart tStart, float minTime)
 {
     Show(identifier, caption, message, type, button1Text, button2Text, clicked);
     mMinTime = minTime;
     mCount = 0;
     mThread = new Thread(tStart);
     mThread.Start();
     while (!mThread.IsAlive);
 }
 protected void ClickHandler()
 {
     Clicked?.Invoke();
 }
Exemplo n.º 19
0
 protected void ClickHandler(UIMouseEventArgs eventArgs)
 {
     Clicked?.Invoke(Page);
 }
Exemplo n.º 20
0
 private void OnClicked(EventArgs e)
 {
     Clicked?.Invoke(this, e);
 }
Exemplo n.º 21
0
 public override void Click()
 {
     Clicked.Invoke(this, EventArgs.Empty);
     isChecked = !isChecked;
 }
Exemplo n.º 22
0
 private void OnLeftClicked()
 {
     Clicked?.Invoke(this, new ClickEventArgs(Mouse.Button.Left));
 }
Exemplo n.º 23
0
        public RadioButton(Array labels,
                           string checkValue             = "",
                           double fontSize               = 20,
                           string fontFamily             = "Arial",
                           FontAttributes fontAttributes = FontAttributes.None,
                           Color?textColor               = null)
        {
            Padding = new Thickness(0);
            Margin  = new Thickness(40, 20, 40, 20);

            var categoryLabels = new List <string>();

            foreach (var label in labels)
            {
                if (!string.IsNullOrEmpty(checkValue) && checkValue.Contains(label.ToString()))
                {
                    categoryLabels.Add(checkValue);
                    continue;
                }
                if (!label.ToString().Contains("\u25CB") || !label.ToString().Contains("\u25CF"))
                {
                    categoryLabels.Add(label.ToString().Insert(0, "\u25CB "));
                }
            }

            var dataTemplate = new DataTemplate(() =>
            {
                var templateGrid = new Grid
                {
                    RowSpacing    = 1,
                    ColumnSpacing = 1,
                };

                var labelText = new Label
                {
                    FontFamily            = fontFamily,
                    FontSize              = fontSize,
                    FontAttributes        = fontAttributes,
                    TextColor             = textColor ?? Color.Black,
                    VerticalTextAlignment = TextAlignment.Center,
                    Margin = new Thickness(10, 0, 10, 0)
                };

                labelText.SetBinding(Label.TextProperty, ".");

                //var checBoxLabel = new Label()
                //{
                //    Text = string.IsNullOrEmpty(checkValue) ? $"\u25CB {labelText.Text}" : $"{checkValue} {labelText.Text}",
                //    FontFamily = fontFamily,
                //    FontSize = fontSize * 2,
                //    TextColor = Color.FromHex("#7f8082")
                //};

                var tapGestureRecognizer     = new TapGestureRecognizer();
                tapGestureRecognizer.Tapped += (sender, args) =>
                {
                    labelText.Text = labelText.Text.Contains("\u25CB") ? labelText.Text.Replace("\u25CB", "\u25CF") : labelText.Text.Replace("\u25CF", "\u25CB");
                    CheckedValue   = labelText.Text;
                    Clicked?.Invoke(this, args);
                };

                foreach (var label in labels)
                {
                    templateGrid.RowDefinitions.Add(new RowDefinition {
                        Height = new GridLength(1, GridUnitType.Auto)
                    });
                }

                StackLayout stackLayout = new StackLayout()
                {
                    Orientation       = StackOrientation.Horizontal,
                    HorizontalOptions = LayoutOptions.StartAndExpand,
                    Children          = { labelText }
                };

                stackLayout.GestureRecognizers.Add(tapGestureRecognizer);
                templateGrid.Children.Add(stackLayout, 0, labels.Length);

                return(new ViewCell {
                    View = templateGrid
                });
            });

            Content = new ListView
            {
                ItemsSource   = categoryLabels,
                ItemTemplate  = dataTemplate,
                Margin        = 5,
                SelectionMode = ListViewSelectionMode.None
            };
        }
Exemplo n.º 24
0
 void OnClick()
 {
     Clicked?.Invoke();
     Blur();
 }
 public void doDownload()
 {
     Log.Debug("_____updater.doDownload()");
     Clicked?.Invoke();
 }
Exemplo n.º 26
0
 protected virtual void OnClicked()
 {
     Clicked?.Invoke(this, EventArgs.Empty);
 }
Exemplo n.º 27
0
 protected void ClickHandler()
 {
     Clicked.InvokeAsync(null);
 }
Exemplo n.º 28
0
 protected virtual void OnClicked(LoadLevelButton obj) => Clicked?.Invoke(obj);
Exemplo n.º 29
0
 public void Click()
 {
     Console.WriteLine("Somebody has clicked a button. Let's raise the event...");
     Clicked?.Invoke(this, EventArgs.Empty);
     Console.WriteLine("All listeners are notified.");
 }
Exemplo n.º 30
0
 public void PropagateUpClicked() =>
 Clicked?.Invoke(this, EventArgs.Empty);
Exemplo n.º 31
0
 private void Button_Click(object sender, RoutedEventArgs e)
 {
     Clicked?.Invoke(new CancelEventArgs());
 }
Exemplo n.º 32
0
 /// <summary>
 /// Creates and initializes a new instance of Image class.
 /// </summary>
 /// <param name="parent">The parent is a given container which will be attached by Image as a child. It's <see cref="EvasObject"/> type.</param>
 /// <since_tizen> preview </since_tizen>
 public Image(EvasObject parent) : base(parent)
 {
     _clicked     = new SmartEvent(this, "clicked");
     _clicked.On += (s, e) => Clicked?.Invoke(this, EventArgs.Empty);
 }
Exemplo n.º 33
0
 protected void HandleClick(UIMouseEventArgs e)
 {
     Clicked.InvokeAsync(EventArgsMapper.ToMouseEventArgs(e));
 }
Exemplo n.º 34
0
        /////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////
        public static void Show(int identifier, string caption, string message, Type type, string button1Text, string button2Text, Clicked clicked)
        {
            mCaption = caption;
            mMessage = message;
            mType = type;

            //int caption_h, message_h;
            //CalcContentY(caption, message, out caption_h, out message_h);

            if(mType == Type.YesNo) {
                mYesButton.Position(new Rect(((Screen.width - mBUTTONS_SEPARATION) / 2) - ButtonProperties.buttonSize, mBUTTONS_Y, ButtonProperties.buttonSize, ButtonProperties.buttonSize));
            } else {
                mYesButton.Position(new Rect((Screen.width - ButtonProperties.buttonSize) / 2, mBUTTONS_Y, ButtonProperties.buttonSize, ButtonProperties.buttonSize));
            }

            mYesButton.Text = button1Text;
            mYesButton.enable = false;
            mNoButton.Text = button2Text;
            mNoButton.enable = false;

            mAlpha.Reset(1, mAnimationDuration, true, 0);
            mState = States.Showing;
            mIdentifier = identifier;
            mClicked = clicked;
            mThread = null;
        }