Commit graph

45 commits

Author SHA1 Message Date
760a836e55 Upgrade license to GPLv3 2013-05-03 00:34:43 +02:00
33b73cac14 Add "Delete" button to detail window
* src/data.c (data_delete_manga): New function, deletes a manga and
  its associated volumes.
  (data_update_manga): Extra free.

* src/eom-detail-window.c (add_menu): Add a "Delete" button to the
  menu.
  (on_delete): New function.  Shows a confirmation dialog and if the
  user pressed "Ok" tries to delete the manga and close the window.

* src/eom-main-window.c (on_row_activated): Connect to the `hide'
  signal instead of the `delete-event' signal.  I couldn't find how te
  emit my own `delete-event' signal, then I found that hide works both
  when I close a window and when the window manager does it.
2012-10-26 00:25:51 +02:00
7ffc87d99d Correctly show changes when total goes down
* src/data.c (data_update_manga): When updating, set `current_qty' to
  the lesser of `current_qty' and `total_qty' so that current will
  never exceed total.  If the update went well remove any volumes that
  have numbers greater than the `total_qty'.

* src/eom-detail-window.c (eom_detail_window_load): Get to upper bound
  of rows, if I need 1.5 rows I actually need 2 rows, what was I
  thinking?  Clear both tables of children before filling them up
  again.
  (cb_destroy): New function.  Just calls destroy in `widget', but
  `gtk_widget_destroy' doesn't seem like a valid `GtkCallback'.
  (on_volume_toggled): When adding a volume fails, revert one from
  `current_qty'.  Don't mess with `self->manga->current_qty', just
  reset the manga id, otherwise we will know that there should be one
  more or less volume, but won't show it in the manga's volumes
  collection.
2012-10-25 21:15:50 +02:00
337a0ba2d2 Show an "infinite" list when total is unknown
* src/eom-detail-window.c (eom_detail_window_load): If the currently
  selected manga's `total_qty' is `0', take, for viewing/editing
  purposes, the manga's `current_qty' + `1' instead.
  (on_volume_toggled): If the current manga's `total_qty' is `0'
  reload the screen after toggling a manga as collected.
2012-10-25 00:25:24 +02:00
18d4d38e8d Add "Read" filter to main window
* src/data.c (data_get_unread_manga): New function.  Gets any manga
  that have unread volumes.
  (data_get_volumes_for_manga): Default `volumes' to `NULL' to make
  sure we don't get garbage by mistake.

* src/eom-main-window.c: Add new enum.  The filter states
  that the main screen has.
  (eom_main_window_load): Get a list of unread manga if the window's
  state indecates we're looking for them.
  (add_menu): Add read filter button, shows only unread manga.
2012-10-25 00:06:31 +02:00
7727a458fb Add - and + button after number entry
These should make it easier to work with numbers.

* src/eom-new-item-dialog.c (change): New function.  Callback for the
  `+' and `-' buttons, either adds or subtracts one from the quantity
  field.
  (eom_new_item_dialog_init): Add `+' and `-' buttons after quantity
  entry.
2012-10-24 23:34:19 +02:00
5849e3d2e4 Change "New Manga" to "New..."
Since it shows a dialog box it's better to indicate that with `...'.
2012-10-24 00:22:22 +02:00
f33ee443de Show read and collected side-by-side
* src/eom-detail-window.c (COLUMNS): Change the number of columns per
  table from 8 to 4 since they now have to share space.
2012-10-24 00:14:55 +02:00
15c7c14368 Add updating of data for manga
The title and total numbers can now be changed.

* src/data.c (data_add_manga): Change `name' to `const gchar*', we're
  not changing it.
  (data_update_manga): New function, updates a manga's information.

* src/eom-detail-window.c (eom_detail_window_load): New function,
  prepares the tables to show the right data.
  (add_menu): New function, adds a menu to the window.
  (eom_detail_window_init): Call `add_menu' and prepare the other
  widgets for showing.
  (on_edit): New function, opens an edit dialog and reloads the screen
  afterwards.
  (set_manga_id): Move data filling to `eom_detail_window_load' and
  widget preparation to `eom_detail_window_init' and call
  `eom_detail_window_load'.

* src/eom-detail-window.h (EomDetailWindow): Add `ctable' and `rtable'
  members, these are the tables that show the data.

* src/eom-main-window.c (on_new): No need to save and copy the name of
  a manga, just destroy the widget later and destroy it always.

* src/eom-new-item-dialog.c (eom_new_item_dialog_class_init): Add
  write-only `manga-id' property.
  (EOM_NEW_PROP_MID): New enum.
  (finalize): New function.  Free the associated manga.
  (get_property): New function.  Get a property, has no properties to
  get for now.
  (set_manga_id): New function.  Show a manga's information in the
  entries.
  (set_property): New function.  Set a property.  Calls `set_manga_id'
  for the `manga-id' property.

* src/eom-new-item-dialog.h (EomNewItemDialog): Add a `Manga' as
  member.
2012-10-24 00:01:06 +02:00
fd7f0ec9a3 Don't expand or fill the volumes tables
Makes it look ugly.

* src/eom-detail-window.c (on_volume_toggled): Remove unused variable
  `txt'.
  (set_manga_id): Remove unused variable `bbox'.  Change the `expand'
  and `fill' arguments to `gtk_box_pack_start' to `FALSE' for both
  tables.
2012-10-23 21:56:26 +02:00
4f54019acb Show some more warnings during compilation 2012-10-23 21:54:42 +02:00
4344e47023 Don't show editable fields in detail window 2012-10-23 01:57:53 +02:00
4d3bb22d33 Rename edit window to detail window
It won't function as an edit window much longer.
2012-10-23 01:49:27 +02:00
ca2dd74798 Set edit window title to manga name 2012-10-23 01:38:04 +02:00
207fc31204 Remove some old comments 2012-10-23 01:34:06 +02:00
f8d8931f18 Update debian/changelog 2012-10-21 21:53:53 +02:00
74e4a497e0 Show volumes in two tables, not lists
First collected volumes, then read volumes.

* src/eom-edit-window.c (COLUMNS): New constant, the number of columns
  to show in the table.
  (create_volume_button): New function.  Creates a button that
  represent the state of a volume.
  (eom_edit_window_init): Don't make the box with volumes force all
  widgets to be the same size.
  (set_manga_id): Show labels above each group of volumes, this way
  nobody has to guess on what they mean.
2012-10-21 21:32:43 +02:00
aa77d2a2f5 Restyle, reindent, refactor (a little) 2012-10-21 19:59:35 +02:00
8e49f0c56e Remember filter after closing edit window
* src/eom-main-window.c (eom_main_window_new): Set the `state'
  variable to 0 the first time around.
  (eom_main_window_load): Remove the `manga' parameter.  Get
  incomplete collections when `state' is `0'.
  (eom_main_window_on_filter): Don't fetch any manga, just set the
  window's `state'.
  (eom_main_window_on_new):
  (eom_main_window_on_edit_closed): No more `manga' parameter for
  `eom_main_window_load'.

* src/eom-main-window.h (struct _EomMainWindow): Add `state' property.

* src/interface.c (interface_show_main_window): No more `manga'
  parameter for `eom_main_window_load'.
2012-10-21 15:26:34 +02:00
3dadedcd16 Update README.md 2012-10-20 02:10:14 +02:00
82d1f15ddd Change version and note about sematic versioning 2012-10-20 02:08:50 +02:00
ebc0ca114b Add silly readme 2012-10-20 01:31:30 +02:00
395c534fd9 Add Collect filter
This filter, in the main window, shows only the manga that still need
to be collected, not the completed ones.

* src/data.c (data_get_manga): Use `data_get_manga_for_query'.
  (data_get_incomplete_manga): New function, get all manga that arent'
  completely collected yet.
  (data_get_manga_for_query): New function, fetches all the manga as
  `query' specifies.

* src/data.h: Add `data_get_incomplete_manga'.

* src/eom-main-window.c (filter_args): New struct. Contains arguments
  needed by the filter callback.
  (eom_main_window_load): Accept a list of manga, this list will be
  used to show the manga, if it's NULL, a list of all manga is used.
  (eom_main_window_add_menu): Add `All' and `Collect' filter buttons.
  (eom_main_window_on_filter): Callback for the filter buttons,
  reloads the list with the correct manga.

* src/eom-main-window.h: Add manga parameter to
  `eom_main_window_load'.

* src/interface.c (interface_show_main_window): Pass `NULL' to
  `eom_main_window_load' to show all manga.
2012-10-20 01:06:39 +02:00
Tom Willemsen
12c5dd9231 Manga volumes can be marked 'read'
In the eom-edit-window a list is shown with all the available manga which indicated which ones have been read
2011-01-30 23:42:13 +01:00
Tom Willemsen
64e573c5b6 Changed email adres 2011-01-20 15:41:19 +01:00
Tom Willemsen
36adf93ae7 Merge branch 'selector' 2010-11-18 00:26:44 +01:00
Tom Willemsen
dd7b20b120 Selection
The main window now actually looks and works like it should as defined by the style guides
2010-11-18 00:23:41 +01:00
Tom Willemsen
ce6f28bf35 Segfault FS#2
Forgot to calloc the collection of collected manga
2010-11-03 23:50:57 +01:00
Tom Willemsen
cb376d3ef4 Added little bit of memory management, removed a lot of g_print 2010-11-03 21:43:18 +01:00
Tom Willemsen
ffdaaa761d Changed section from user/other to user/utilities 2010-10-28 23:56:15 +02:00
Tom Willemsen
3d708c7b5b Merge branch 'deb' 2010-10-28 23:51:31 +02:00
Tom Willemsen
5368f56996 Created files for packaging as .deb 2010-10-28 23:51:06 +02:00
Tom Willemsen
10ac842951 Makes
using automake it can be built and installed
2010-10-25 23:18:15 +02:00
Tom Willemsen
ad9ed8ffaf Compiles with automake 2010-10-25 22:57:25 +02:00
Tom Willemsen
0c774c7fac First try 2010-10-22 12:57:06 +02:00
Tom Willemsen
bf85ca8598 Edit which volumes you have 2010-10-22 02:19:47 +02:00
Tom Willemsen
bbc8844d49 Woops 2010-10-21 21:02:54 +02:00
Tom Willemsen
8a45361b4f Changed name from Collections to Eye on Manga 2010-10-21 21:00:26 +02:00
Tom Willemsen
4b153e25e4 Merge branch 'data' into eye-on-manga
Conflicts:
	src/c-edit-window.c
2010-10-21 19:31:54 +02:00
Tom Willemsen
e963880636 Edit screen 2010-10-21 19:29:56 +02:00
Tom Willemsen
dcf562d835 Edit screen 2010-10-21 19:29:14 +02:00
Tom Willemsen
10901f7dcb Edit window 2010-10-20 22:37:54 +02:00
Tom Willemsen
6628dddb27 Change qty and add items
Current quantity can be changed by clicking add or remove
Add new series
2010-10-19 23:59:55 +02:00
Tom Willemsen
c34819ee2c Data
Data is gotten from an sqlite3 database
New series can be added to the database
2010-10-19 01:28:46 +02:00
Tom Willemsen
767ca99d33 Initial commit 2010-10-17 13:48:02 +02:00