コード例 #1
0
        /// <summary>
        /// Applies control template.
        /// </summary>
        public override void OnApplyTemplate()
        {
            _sliceCanvasDecorator = (Border)TreeHelper.TemplateFindName("PART_SliceCanvasDecorator", this);
            _sliceCanvasDecorator.SizeChanged += new SizeChangedEventHandler(OnGraphCanvasDecoratorSizeChanged);
            _sliceCanvas = (Canvas)TreeHelper.TemplateFindName("PART_SliceCanvas", this);

            _balloon = (Balloon)TreeHelper.TemplateFindName("PART_Balloon", this);

            AddSlicesToCanvas();

            _legend = (Legend)TreeHelper.TemplateFindName("PART_Legend", this);

            #if WINDOWS_PHONE
            _legend.ManipulationStarted += new EventHandler<ManipulationStartedEventArgs>(OnLegendManipulationStarted);
            #endif

            UpdateLegend();
        }
コード例 #2
0
 private void AssignBalloon()
 {
     _balloon = (Balloon)TreeHelper.TemplateFindName("PART_Balloon", this);
 }
コード例 #3
0
 private void AssignBalloon()
 {
     _balloon = (Balloon)TreeHelper.TemplateFindName("PART_Balloon", this);
     #if !SILVERLIGHT
     _balloon.BorderBrush = _balloonBrush;
     #endif
 }