Maarten ter Huurne
02dd542ea5
Renamed section left/right images
...
Since we adopted the circular navigation, there is no more need for
separate enabled and disabled images.
2013-08-12 01:38:32 +02:00
Maarten ter Huurne
76117663ff
Converted the context menu to a Layer
...
This fixes a bug with the captured background being wrong when using
double buffering. Also it ensures that for example the clock in the
status bar is updated when the context menu is open.
2013-08-11 23:46:04 +02:00
Maarten ter Huurne
8de59b5c04
Animate section header changes
2013-08-11 05:17:12 +02:00
Maarten ter Huurne
71f4391cda
Moved all code for opening the context menu into the Menu class
...
All of the entries in the context menu affect sections and links, so
the context menu should be considered part of the main menu, not of
the global / background context.
2013-08-09 19:09:57 +02:00
Maarten ter Huurne
4a392a9173
Use reference to SurfaceCollection in Menu::paint()
...
This should have been a reference all along, but somehow I forgot to
actually type the "&".
2013-08-06 19:57:38 +02:00
Maarten ter Huurne
6d868a895a
Implemented layer system for painting and events
...
The long term goal is to be able to use a single event loop regardless
of which submenu or alternative mode is active.
2013-08-06 01:55:32 +02:00
Maarten ter Huurne
074668336e
Handle menu-related buttons inside Menu class
2013-08-05 16:43:22 +02:00
Maarten ter Huurne
e6300ab07a
Changed section headers to be displayed in a circular fashion
...
Instead of having a list and wrapping between beginning and end, always
put the current section in the middle and show the previous and next
sections using wrap-around.
2013-08-05 14:54:42 +02:00
Maarten ter Huurne
bdf3cfdf86
Moved linkColumns and linkRows fields into Menu class
2013-08-05 00:51:36 +02:00
Maarten ter Huurne
8d7ac6e0ba
Center links horizontally
2013-08-05 00:42:59 +02:00
Maarten ter Huurne
f65a59a02f
Fixed scrollbar size for links area
...
Made sure it fills the space between the top and bottom bar. Use a one
pixel margin; I tried without margins but it didn't look nice.
Also cleaned up the paint code a bit.
2013-08-05 00:02:56 +02:00
Maarten ter Huurne
41b0551595
Moved menu touch handling code into Menu class
2013-08-04 23:19:15 +02:00
Maarten ter Huurne
1eeba171dd
Moved menu painting code into Menu class
2013-08-04 21:14:29 +02:00
Maarten ter Huurne
a9b5d8bd19
Moved most Menu::loadIcons() code into Link/LinkApp classes
...
The code still has a lot of overlap with the other methods of Link and
LinkApp, but at least it is in the same place now.
Since this was the last outside use, setIconPath() could be declared
as 'protected'.
2013-08-02 21:24:20 +02:00
Maarten ter Huurne
40372d14ef
Cleaned up Menu::loadIcons()
...
Most changes involve not calling the same method with the same
arguments again and again. Also use C++11 range-based loops.
2013-08-02 20:53:38 +02:00
Paul Cercueil
88f54e1ccc
Drop incredibly dirty and huge file FastDelegate.h
...
It's way too over-engineered for what we need to do, and we can
do much simpler using C++11.
2013-07-29 12:58:25 -04:00
Paul Cercueil
5255bf6de3
Destroy all registered Monitor objects when the Menu is destroyed
2013-07-19 14:50:46 -04:00
Paul Cercueil
9dae4b76df
Accept meta-data named *.all.desktop in OPK files
...
This could be used to create platform-independent packages. It can
be useful for instance in the case where the executable is a script,
or when the package points to an executable that is present on all
systems on which OPKs are supposed to run.
2013-07-19 14:41:17 -04:00
Paul Cercueil
b6dfdc6ef5
Stop watching a directory when it has been reported as removed
2013-07-19 14:35:45 -04:00
Paul Cercueil
84a987e9d5
When loading multiple OPKs, don't order links each time one is added
2013-07-19 12:50:20 -04:00
Paul Cercueil
69b9657af4
Add function openPackagesFromDir() to simplify constructor of Menu
2013-07-19 12:01:25 -04:00
Paul Cercueil
36c4205e0e
Don't try to read OPKs in /media/./apps and /media/../apps
2013-07-19 11:57:35 -04:00
Paul Cercueil
04d9d9322d
Remove trailing slash from CARD_ROOT
2013-07-19 11:54:09 -04:00
Paul Cercueil
5e7bcf3a1f
Remove all links of an "apps" dir when it is removed or renamed
2013-07-18 21:34:03 -04:00
Paul Cercueil
cc869c07a8
Fix link insertion/deletion when OPKs are overwritten from SSH/FTP
2013-07-18 21:27:27 -04:00
Paul Cercueil
bcb3e98ddc
Order the links in alphabetical order
2013-07-18 17:38:09 -04:00
Paul Cercueil
dfad7c39a7
Remove all links of an OPK when moved out of the monitored folder
...
It was previously removing only one link, but an OPK can provide
multiples links.
2013-07-18 16:29:56 -04:00
Paul Cercueil
13b3d8e0ca
Monitor OPK folders using inotify and automatically add/delete links
2013-07-16 13:36:18 -04:00
Paul Cercueil
1467c9b9d7
Don't try to find OPKs inside non-existing directories
2013-07-16 12:44:30 -04:00
Paul Cercueil
78ad051756
Split huge function readPackages into two functions
2013-07-10 18:57:56 -04:00
Paul Cercueil
c58b3a535e
Update GMenu2X to use the latest libopk v1.0 API
2013-05-26 19:06:53 -04:00
Maarten ter Huurne
90ec4b9ace
Ignore OPK files of which the name starts with a dot
...
These are not actual OPK files, but metadata (I assume) storage that
Mac OS X adds to vfat file systems. The current version of libopk has
extremely poor error handling, so ignoring these files avoids a crash.
But even when libopk is fixed, not trying to open these files as OPKs
will be useful since it saves time.
2013-01-24 23:26:30 +01:00
Paul Cercueil
efdf766102
Enable support for multiple .desktop for one platform inside OPKs
2012-11-29 23:44:58 -03:00
Paul Cercueil
4a60aa000d
Load the OPK in the section defined by their "Categories" parameter
2012-10-09 01:41:57 +02:00
Paul Cercueil
cd4809343b
During init, load all packages in CARD_ROOT/*/apps
2012-10-07 21:51:25 +02:00
Paul Cercueil
3dc12d06ea
menu.cpp: Don't use stat() to know if a FS entry is a directory
...
The pointer returned by readdir() already informs us of the type
of the FS entry.
2012-10-06 17:38:58 +02:00
Paul Cercueil
7687212b4e
Removed the "wrapper" feature.
...
It is up to the system to restart GMenu2X when the application exits.
2012-04-13 18:12:30 +02:00
Maarten ter Huurne
d2413d8233
Added missing #includes.
...
Fixes compilation with GCC 4.7.0.
2012-03-24 12:00:25 +01:00
Maarten ter Huurne
57ad81e3df
Merged LinkAction class into its base class.
...
LinkApp now calls its launch method via the delegate mechanism instead of
via an overridden virtual method. This should make it easier to move the
launch method out of LinkApp and into the GMenu2X main class.
2012-03-24 11:57:21 +01:00
Maarten ter Huurne
1ad6b2f25a
Made GMenu2X::ts private.
...
Pass Touchscreen reference to constructors instead of pulling it from
the GMenu2X class.
2011-12-23 14:03:05 +01:00
Maarten ter Huurne
a01d892eb6
More header cleanups.
...
This time the focus was on removing namespace imports from headers.
2011-10-23 16:43:56 +02:00
Ayla
3995133fa5
When deleting a link, check if the icon is used elsewhere before unloading it.
2011-09-18 13:22:02 +02:00
Ayla
4636a84eef
Create the "sections" user directory if required, when creating a new link.
...
It previously assumed that this directory was present, which isn't
the case all the time.
2011-07-25 12:05:24 +02:00
Ayla
81a607c36e
Fixed a good number of memory leaks.
...
The objects created with "new" were destroyed with "free()",
instead of "delete"; as a result, the destructors were never called.
2011-07-20 13:43:25 +02:00
Ayla
f7817b19ab
The links will now be loaded from both the system and the user-specific directories.
2011-07-11 02:49:44 +02:00
Ayla
114fe594d0
The sections directories shall now be found under the user-specific directory.
2011-04-03 11:44:08 +02:00
Ayla
8336c83129
If the "sections/" directory is missing, we create it as well as some default sections (settings, applications...).
2011-04-03 11:34:40 +02:00
Xiangfu Liu
91d3fea2ec
fixed section display not correct in ben nanonote
2011-01-13 17:20:17 +08:00
Ayla
08468776f4
When a foo.dge file is loaded, the image file foo.png will be automatically assigned.
2010-09-18 21:28:54 +02:00
Ayla
7c9364780b
Replaced every message output by calls to the log macros.
2010-09-17 22:31:09 +02:00