2020-05-26 16:34:33 +00:00
|
|
|
//
|
|
|
|
// GuiGameScraper.h
|
|
|
|
//
|
|
|
|
// Single game scraping user interface.
|
|
|
|
// This interface is triggered from GuiMetaDataEd.
|
2020-06-06 12:14:13 +00:00
|
|
|
// GuiScraperSearch is called from here.
|
2020-05-26 16:34:33 +00:00
|
|
|
//
|
|
|
|
|
2014-06-25 16:29:58 +00:00
|
|
|
#pragma once
|
2017-10-31 17:12:50 +00:00
|
|
|
#ifndef ES_APP_GUIS_GUI_GAME_SCRAPER_H
|
|
|
|
#define ES_APP_GUIS_GUI_GAME_SCRAPER_H
|
2014-06-25 16:29:58 +00:00
|
|
|
|
|
|
|
#include "components/NinePatchComponent.h"
|
2020-06-06 12:14:13 +00:00
|
|
|
#include "guis/GuiScraperSearch.h"
|
2017-11-01 22:21:10 +00:00
|
|
|
#include "GuiComponent.h"
|
2014-06-25 16:29:58 +00:00
|
|
|
|
|
|
|
class GuiGameScraper : public GuiComponent
|
|
|
|
{
|
|
|
|
public:
|
2020-05-26 16:34:33 +00:00
|
|
|
GuiGameScraper(
|
|
|
|
Window* window,
|
|
|
|
ScraperSearchParams params,
|
|
|
|
std::function<void(const ScraperSearchResult&)> doneFunc);
|
2014-06-25 16:29:58 +00:00
|
|
|
|
|
|
|
void onSizeChanged() override;
|
|
|
|
|
|
|
|
bool input(InputConfig* config, Input input) override;
|
|
|
|
void update(int deltaTime);
|
2020-06-07 18:09:02 +00:00
|
|
|
|
2014-06-25 16:29:58 +00:00
|
|
|
virtual std::vector<HelpPrompt> getHelpPrompts() override;
|
2020-06-07 18:09:02 +00:00
|
|
|
HelpStyle getHelpStyle() override;
|
2014-06-25 16:29:58 +00:00
|
|
|
|
|
|
|
private:
|
|
|
|
bool mClose;
|
|
|
|
void close();
|
|
|
|
|
|
|
|
ComponentGrid mGrid;
|
|
|
|
NinePatchComponent mBox;
|
|
|
|
|
|
|
|
std::shared_ptr<TextComponent> mGameName;
|
|
|
|
std::shared_ptr<TextComponent> mSystemName;
|
2020-06-06 12:14:13 +00:00
|
|
|
std::shared_ptr<GuiScraperSearch> mSearch;
|
2014-06-25 16:29:58 +00:00
|
|
|
std::shared_ptr<ComponentGrid> mButtonGrid;
|
|
|
|
|
|
|
|
ScraperSearchParams mSearchParams;
|
|
|
|
|
|
|
|
std::function<void()> mCancelFunc;
|
|
|
|
};
|
2017-10-31 17:12:50 +00:00
|
|
|
|
|
|
|
#endif // ES_APP_GUIS_GUI_GAME_SCRAPER_H
|