aseprite/src/ui/scroll_helper.h
David Capello 9772f99303 Add scroll bars to Timeline widget (fix #732)
Changes:
- Added ui::ScrollableViewDelegate so ui::ScrollBar can be child of
  a non-ui::View widget.
- Added a generic ui::setup_scrollbars() utility to locate
  horizontal/vertical scrollbars depending on the scrollable area and
  the available viewport area.
- Replaced Timeline::m_scroll_x/y ints with m_hbar/m_vbar widgets.
- Added transparent scrollbar look & feel.
- Added a "hover" state to mini-scrollbars used in sprite editors.
2015-09-17 15:19:47 -03:00

27 lines
601 B
C++

// Aseprite UI Library
// Copyright (C) 2001-2013, 2015 David Capello
//
// This file is released under the terms of the MIT license.
// Read LICENSE.txt for more information.
#ifndef UI_SCROLL_HELPER_H_INCLUDED
#define UI_SCROLL_HELPER_H_INCLUDED
#pragma once
#include "gfx/rect.h"
#include "gfx/size.h"
namespace ui {
class ScrollBar;
void setup_scrollbars(const gfx::Size& scrollableSize,
gfx::Rect& viewportArea,
Widget& parent,
ScrollBar& hbar,
ScrollBar& vbar);
} // namespace ui
#endif