Files
recycled-ni-neutrino/src/gui/widget/buttons.h
Stefan Seyfried 70cbcb6bb5 replace framebuffer.h include with forward declaration
instead of including framebuffer.h almost everywhere, replace it with
class CFrameBuffer forward declarations and/or generic system includes.
Add a hack to define fb_pixel_t to config.h (one reason for
framebuffer.h includes was the fb_pixel_t define)


Origin commit data
------------------
Branch: ni/coolstream
Commit: e490f84ea8
Author: Stefan Seyfried <seife@tuxbox-git.slipkontur.de>
Date: 2017-02-05 (Sun, 05 Feb 2017)



------------------
This commit was generated by Migit
2017-02-07 17:23:42 +01:00

92 lines
2.7 KiB
C++

#ifndef __gui_widget_buttons_h__
#define __gui_widget_buttons_h__
/*
* $Id: buttons.h,v 1.6 2010/07/12 08:24:55 dbt Exp $
*
* (C) 2003 by thegoodguy <thegoodguy@berlios.de>
*
* This program is free software; you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation; either version 2 of the License, or
* (at your option) any later version.
*
* This program is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU General Public License for more details.
*
* You should have received a copy of the GNU General Public License
* along with this program; if not, write to the Free Software
* Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
*
*/
#include <driver/fontrenderer.h>
#include <system/localize.h>
#include <gui/color.h>
#include <vector>
struct button_label
{
const char * button;
neutrino_locale_t locale;
};
struct button_label_ext
{
const char * button;
neutrino_locale_t locale;
const char * text;
int width;
bool maximize;
};
int paintButtons( const button_label * const content,
const int &count,
const int &x,
const int &y,
const int &footerheight,
const int &footerwidth,
const int &maxwidth,
bool show = true,
int *wantedwidth = NULL,
int *wantedheight = NULL);
int paintButtons( const button_label_ext * const content,
const int &count,
const int &x,
const int &y,
const int &footerheight,
const int &footerwidth,
const int &maxwidth,
bool show = true,
int *wantedwidth = NULL,
int *wantedheight = NULL);
int paintButtons( const int &x,
const int &y,
const int &footerwidth,
const int &count,
const button_label * const content,
const int &maxwidth,
const int &footerheight = 0);
int paintButtons( const int &x,
const int &y,
const int &footerwidth,
const uint &count,
const struct button_label * const content,
const int &maxwidth,
const int &footerheight = 0,
std::string tmp = "", /* just to make sure compilation breaks */
bool vertical_paint = false,
const uint32_t fcolor = COL_MENUFOOT_TEXT,
const char * alt_buttontext = NULL,
const uint &buttontext_id = 0,
bool show = true,
const std::vector<neutrino_locale_t>& all_buttontext_id = std::vector<neutrino_locale_t>());
#endif /* __gui_widget_buttons_h__ */