Commit Graph

1747 Commits

Author SHA1 Message Date
David Capello
d46616e71f Fix problems with Allegro + MacOSX + main().
Renamed the application main to app_main() so it's called from "she"
library. It's impossible to avoid dirty main() tricks with Allegro 4.
2012-08-24 00:24:51 -03:00
David Capello
ae777018e2 Merge branch 'dev' of git@github.com:dacap/aseprite.git into dev 2012-08-23 23:52:15 -03:00
David Capello
df48deaef8 Initialize CheckUpdate process only in GUI mode.
E.g. If the program is executed with --help we don't need to
check for updates.
2012-08-23 23:51:27 -03:00
David Capello
c539306327 Fix create_release.sh script. 2012-08-23 22:29:40 -03:00
David Capello
fb5f086f0f Add "ui::dirty_display_flag" flag to avoid flipping to the screen continuously.
This is a temporal fix to save more CPU. It will be refactored for next
versions.
2012-08-23 22:25:56 -03:00
David Capello
6971426d61 Fix gcc compilation error with App::Modules() ctor. 2012-08-23 22:02:09 -03:00
David Capello
91e02a496a Remove ColorBar border at the right-side. 2012-08-23 21:55:17 -03:00
David Capello
29898744fe Fix issue #160, crashes undoing critical actions like "remove layer" or "remove frame".
The OpenGroup & CloseGroup undoers now save the current SpritePosition
when the Undoer instance is created. Before we were using the current
Layer and Frame at the moment of the OpenGroup creation, it was generating
buggy undoers.
2012-08-23 21:44:41 -03:00
David Capello
919e892748 Add LayerIndex and SpritePosition types. 2012-08-23 21:32:55 -03:00
David Capello
7f2f965b9c Check if keyboard_driver is installed before using it in _al_win_kbd_update_shifts().
The function _handle_key_press() cannot be used if keyboard_driver is
NULL and this can happen in the creation process of the window if the user
is pressing keys.
2012-08-22 22:34:03 -03:00
David Capello
3698195375 wwnd.c: Do not handle mouse events if the win_gfx_driver is not initialized.
It fix a deadlock when we try to create a window that doesn't fit the
desktop and we have the mouse above that opened window (which could
be pretty common).
2012-08-22 22:21:39 -03:00
David Capello
92f9302c85 wddwin.c: Rename _destroy_directx_forefront_bitmap() to _destroy_directx_forefront_bitmap_extras().
Call the function only one time in gfx_directx_win_exit().
2012-08-22 22:05:19 -03:00
David Capello
1c031ee31d Update resources_win32.rc version. 2012-08-22 21:28:40 -03:00
David Capello
b190e9e791 Add update_version.sh script (which updates resources_win32.rc version now). 2012-08-22 21:28:31 -03:00
David Capello
e89d087a04 Add validation checks for scripts/ that they are being executed from the expected directory. 2012-08-22 21:26:52 -03:00
David Capello
e31affc017 Add some items in TODO about UndoTransaction which is a huge class to split. 2012-08-22 21:05:34 -03:00
David Capello
f541fc8789 Add DataRecovery and Backup classes. They do nothing at the moment. 2012-08-22 21:05:02 -03:00
David Capello
cae19827f5 Add DocumentEvent class so all DocumentObserver's member functions receive one parameter. 2012-08-18 23:45:37 -03:00
David Capello
a37a505566 Fix Observable::notifyObservers<> member functions to call specific Observers members explicitly. 2012-08-18 22:54:03 -03:00
David Capello
4e7103d6d1 Fix BindAdapter1_fun member function arguments. 2012-08-18 22:52:56 -03:00
David Capello
85f7bf8ba8 Rename Layer::add/remove/move_layer member functions to add/remove/stackLayer. 2012-08-18 22:21:42 -03:00
David Capello
3f7d7b00b7 Fix link problem with gcc compiler and loadpng library. 2012-08-18 17:51:37 -03:00
David Capello
25605d8c06 Fix UI unit tests: they must use/be linked to "she" library. 2012-08-18 17:51:26 -03:00
David Capello
ce84dfbef6 Merge branch 'dev' of git@github.com:dacap/aseprite.git into dev 2012-08-18 17:51:14 -03:00
David Capello
acc13e9385 Add DocumentObserver and now the Document is an Observable class. 2012-08-18 17:50:36 -03:00
David Capello
2ca98391e0 Add Observable template. 2012-08-18 17:47:00 -03:00
David Capello
3b99e73734 Rename "listener" to "observer" which is better to reference the "Observer" pattern. 2012-08-18 15:22:23 -03:00
David Capello
c757ff7231 Minor error in fs_unix.h with std::runtime_error symbol. 2012-08-16 12:10:30 -03:00
David Capello
dc9a2ced94 Add file-system functions in base. 2012-08-16 11:57:25 -03:00
David Capello
e976005cdd Initialize random seed in main.cpp. 2012-08-16 11:17:49 -03:00
David Capello
61b6500f72 Fix marching ants flicker when the user draws. 2012-08-11 21:44:46 -03:00
David Capello
3082eae163 Minor changes: Removing dependencies with allegro.h file. 2012-08-11 10:42:51 -03:00
David Capello
c6fe95231d Convert the mouse cursor into an ui::Overlay (now it support alpha channel).
- Added Cursor class and CursorType enum.
2012-08-10 23:14:54 -03:00
David Capello
d7862744b4 Merge branch 'master' of git@github.com:dacap/aseprite.git 2012-08-06 01:20:12 -03:00
David Capello
237bec80f2 Add overlays (ui::Overlay and ui::OverlayManager classes). 2012-08-06 01:17:29 -03:00
David Capello
89cb9d098c Move some base UI logic to handle the main display from modules/gui.cpp to she library. 2012-08-05 21:16:16 -03:00
David Capello
f5ad8c86d3 Fix infinite loop when rectgrid() is called with w == 0 or h == 0. 2012-08-02 19:50:27 -03:00
David Capello
2ffe54584a Fix gcc problem using std::stream with forward-declarations only without including <sstream>. 2012-07-18 08:59:31 -03:00
David Capello
525851e6a1 The color bar is now resizable.
- Added Splitter::Type so it can be by pixel or by percentage.
- Added Widget::load/saveLayout functions and Widget::onLoad/SaveLayout
  events.
- Added LayoutIO interface so we can delegate the serialization of the
  layout.
2012-07-18 01:10:43 -03:00
David Capello
25fc113c37 Fix issue #142: Crash keeping a key pressed while we're en menu logic.
We cannot send another Menu::closeAll() request if we are processing
other open/close popup requests. This also fix a crash if we keep the left
or right key pressed to navigate through menus.
2012-07-17 23:18:43 -03:00
David Capello
8764f018c7 Minor change in menu.cpp. 2012-07-17 23:01:05 -03:00
David Capello
5da37e237b Fix a bug introduced in aseprite 0.9.2, commit 8a1295c025.
Widget::getMnemonicChar() can return 0, and we should pre-check this
value before we compare the mnemonic with the pressed ascii char.
2012-07-17 23:00:55 -03:00
David Capello
b090629897 Fix for issue #143: Do not call FileList::setCurrentFolder() with start_folder = NULL.
It's strange why start_folder could be NULL in this case, but there is
a chance that FileSystemModule::getFileItemFromPath() fails and returns
NULL.
2012-07-17 22:12:41 -03:00
David Capello
14f24b1181 Refactor: replace JList with std::vector<> or std::list<>. 2012-07-17 21:42:02 -03:00
David Capello
f8f5b2b515 Fix problems with double main definition on Linux. 2012-07-16 13:15:44 -03:00
David Capello
617dd014d4 Fix file_unittest.cpp to use she library instead of ScopedAllegro. 2012-07-16 13:15:24 -03:00
David Capello
cf90dbd734 Merge remote-tracking branch 'origin/master' 2012-07-15 02:06:27 -03:00
David Capello
8dd42cc653 Fix problems with printf-like functions using %d with size_t fields (instead of %lu). 2012-07-15 02:02:29 -03:00
David Capello
07a8b18955 Fix compilation error with gcc 64 bit converting void* to int. 2012-07-15 00:58:46 -03:00
David Capello
35f1249662 Add "she" layer.
This is the starting point to create a layer to isolate Allegro access.
In the future, we will be able to switch to SDL or Allegro 5 easily.
Anyway this will be a progressive refactoring.
2012-07-14 16:55:16 -03:00