1
0
mirror of git://projects.qi-hardware.com/gmenu2x.git synced 2025-04-21 12:27:27 +03:00

Give LinkApp a direct reference to the InputManager object instead of fetching it from the GMenu2X object.

This commit is contained in:
Maarten ter Huurne
2010-07-27 23:22:46 +02:00
parent 0ce743426a
commit 9fcaa2b8fa
3 changed files with 12 additions and 8 deletions

View File

@@ -269,7 +269,7 @@ bool Menu::addLink(string path, string file, string section) {
#ifdef DEBUG
cout << "\033[0;34mGMENU2X:\033[0m Section: " << sections[isection] << "(" << isection << ")" << endl;
#endif
LinkApp* link = new LinkApp(gmenu2x, linkpath.c_str());
LinkApp* link = new LinkApp(gmenu2x, gmenu2x->input, linkpath.c_str());
link->setSize(gmenu2x->skinConfInt["linkWidth"],gmenu2x->skinConfInt["linkHeight"]);
links[isection].push_back( link );
}
@@ -425,7 +425,7 @@ void Menu::readLinks() {
sort(linkfiles.begin(), linkfiles.end(),case_less());
for (uint x=0; x<linkfiles.size(); x++) {
LinkApp *link = new LinkApp(gmenu2x, linkfiles[x].c_str());
LinkApp *link = new LinkApp(gmenu2x, gmenu2x->input, linkfiles[x].c_str());
link->setSize(gmenu2x->skinConfInt["linkWidth"],gmenu2x->skinConfInt["linkHeight"]);
if (link->targetExists())
links[i].push_back( link );