Esempio n. 1
0
        private void BuildPage()
        {
            _defaultBackgroundColor = Style.Backgrounds[(int)StateType.Normal];

            _toolbar = new HBox();
            _content = new GtkFormsContainer();

            var root = new VBox(false, 0);

            _headerContainer = new GtkFormsContainer();
            root.PackStart(_headerContainer, false, false, 0);

            _image        = new ImageControl();
            _image.Aspect = ImageAspect.Fill;

            _contentContainerWrapper = new GtkFormsContainer();
            _contentContainerWrapper.SizeAllocated += OnContentContainerWrapperSizeAllocated;
            _contentContainer = new Fixed();
            _contentContainer.Add(_image);
            _contentContainerWrapper.Add(_contentContainer);

            root.PackStart(_contentContainerWrapper, true, true, 0);             // Should fill all available space

            Attach(root, 0, 1, 0, 1);

            ShowAll();
        }
Esempio n. 2
0
        private void Build()
        {
            _image        = new ImageControl();
            _image.Aspect = ImageAspect.AspectFill;

            Add(_image);
            Add(_widget);
        }
Esempio n. 3
0
 public override void Destroy()
 {
     base.Destroy();
     if (_contentContainerWrapper != null)
     {
         _contentContainerWrapper.SizeAllocated -= OnContentContainerWrapperSizeAllocated;
         _contentContainerWrapper = null;
     }
     _contentContainer = null;
     _image            = null;
     _toolbar          = null;
     _content          = null;
     _headerContainer  = null;
 }
Esempio n. 4
0
        private void BuildCarousel()
        {
            _pages = new List <CarouselPage>();

            _image        = new ImageControl();
            _image.Aspect = ImageAspect.Fill;
            Add(_image);

            _wrapperBox = new EventBox();
            _wrapperBox.VisibleWindow = false;
            _root = new Table(1, 1, true);
            _wrapperBox.Add(_root);

            _wrapperBox.ButtonPressEvent   += OnCarouselButtonPressEvent;
            _wrapperBox.ButtonReleaseEvent += OnCarouselButtonReleaseEvent;

            Add(_wrapperBox);
        }