Commit Graph
353 Commits
Author SHA1 Message Date
Bharat Mediratta b550a06045 Rename $album to $target in move_to() 2009-09-10 10:08:29 -07:00
Tim Almdal 2bbe162339 A better fix for #741... the original problem was that the source and album variables were reversed 2009-09-10 10:09:09 -07:00
Tim Almdal bea89be268 If the current drop target is not defined, in that we have moved out of the range of the current li elements, then assume the drop is occurring at the end of the list items. Fixes #742 2009-09-10 07:59:29 -07:00
Tim Almdal eb345cb870 Changed the check in organize_Controller::move_to:
1) check that target and source are not the same.
2) check that the source is not already a child of the target (use to be a
   descendant) Fixes #741.
2009-09-10 06:17:21 -07:00
Bharat Mediratta 9fbdcf3efd Change the module installer so that you don't need to provide your own
install() function if all you're going to do is to set the version of
the module from module.info into the database.  This means that for some
simple modules, you don't need an install.php file at all.
2009-09-05 13:39:30 -07:00
Bharat Mediratta ab7323d17b Fix the url in the call to get subsequent entries to have the right
url, and to be json.  Fixes #719, which I introduced in my refactor.
2009-09-04 21:27:23 -07:00
Bharat Mediratta dfb2e3dd02 Add an icon to the context menu option. 2009-08-31 23:27:46 -07:00
Bharat Mediratta 0513713fde Add 'organize album' to the context menu. 2009-08-31 21:05:21 -07:00
Bharat Mediratta c10b5cc69c Minor refactoring. 2009-08-30 17:00:33 -07:00
Bharat Mediratta 7015948357 Merge branch 'master' of git@github.com:/gallery/gallery3 2009-08-30 16:20:52 -07:00
Andy Staudacher e7f5e0a9a3 Merge commit 'upstream/master'
Conflicts:

	modules/gallery/views/l10n_client.html.php
	modules/organize/views/organize_tree.html.php
	modules/server_add/helpers/server_add_event.php
2009-08-30 18:27:40 -07:00
Bharat Mediratta 74e204b557 Don't mark colors !important. 2009-08-30 16:17:53 -07:00
Bharat Mediratta 0dba5857fa Make comments consistent. 2009-08-30 16:16:39 -07:00
Bharat Mediratta 4593297533 Remove extra padding line 2009-08-30 16:15:54 -07:00
Bharat Mediratta d47a4de029 Get rid of as much jitter as possible in the organize tree. 2009-08-30 16:11:28 -07:00
Bharat Mediratta 2cf52a4718 Tighten up a class attr. 2009-08-30 15:54:56 -07:00
Bharat Mediratta 6fdb5cddf8 Make the lasso more prominent and the colors consistent. 2009-08-30 15:45:35 -07:00
Bharat Mediratta a015078cca Change the higlight/selection behavior so that we don't use opacity to
indicate selection state.  It's too difficult to tell opacity
differences on light colored photos.  This approach models what
WinXP does.
2009-08-30 15:42:43 -07:00
Bharat Mediratta 64d40397fe Simplify over-targetted CSS. 2009-08-30 15:34:47 -07:00
Bharat Mediratta db03c5d799 Don't try to move an item into its own descendant hierarchy. Just leave it out of the move for now. 2009-08-30 15:09:13 -07:00
Bharat Mediratta 53390ba79a CSS rename: gMicroThumbXxx -> gOrganizeMicroThumbXxx to make it clear
that this is organize only.
2009-08-30 14:58:26 -07:00
Bharat Mediratta 5cce88cd04 Rename gAlbumText to gOrganizeAlbumText for consistency since this is
an organize-only construct.
2009-08-30 14:50:53 -07:00
Bharat Mediratta a498d37763 remove unused #gOrganizeDialog 2009-08-30 14:49:51 -07:00
Bharat Mediratta c615918829 Manage the selection so we don't automatically select an album
whenever we expand a tree.
2009-08-30 14:40:55 -07:00
Bharat Mediratta d1ade6620e Precalculate the organize tree based on the selected album and render
it right away while still allowing incremental tree loading.
2009-08-30 14:35:27 -07:00
Andy Staudacher b9bd1681a3 Update all code to use helper method html::clean(), html::purify(), ... instead of SafeString directly. 2009-08-29 22:54:20 -07:00
Bharat Mediratta 483d8df91b Change the organize tree to expand/collapse. It doesn't properly open
up to the album that you're viewing, and if you move a photo to a
different album it'll reload the entire album tree.
2009-08-29 16:33:22 -07:00
Andy Staudacher c4d5ecde66 L10n fixes for the admin_languages page, and JS/XSS cleanup of the organize views. 2009-08-29 14:38:47 -07:00
Bharat Mediratta 775987dff9 Fix a bug where organize doesn't properly generate the tree at the root album. 2009-08-29 11:29:38 -07:00
Bharat Mediratta 4408ed0684 Remove stray blank line. 2009-08-29 10:56:35 -07:00
Bharat Mediratta b833cb6073 Get rid of the task infrastructure. The multiple requests greatly
slow down simple operations.  We may run into problems with more
complex operations, but let's only add tasks into the mix when it's
clear that we need them.
2009-08-29 10:48:23 -07:00
Bharat Mediratta f257cd3d69 Major refactor of organize:
* Clean up naming conventions for variables in the controller
  so that we specifically refer to albums with $album_id, etc.

* Move complexity for drawing tree out of the controller and into
  the view.

* Simplify task definitions to get rid of extraneous text

* Change __PLACEHOLDERS__ to clearly define which is the album
  and which is the item that we're moving before/after

* Remove as many CSS ids as we can from the tree view to keep
  things simple
2009-08-29 10:00:47 -07:00
Bharat Mediratta cb2171d082 Display the sort order in the Organize dialog, and allow users to
change the sort order on the fly.
2009-08-28 14:27:37 -07:00
Bharat Mediratta b9aca313fa Fix a couple of off-by-one errors. 2009-08-28 11:41:06 -07:00
Bharat Mediratta 48e84243d2 Update help text to eliminate 'edit' since we don't do that yet, and change "items" to "photos". 2009-08-28 11:21:19 -07:00
Bharat Mediratta 76e541745f Refactor rearrange_task_handler to have a more linear flow. 2009-08-28 11:13:04 -07:00
Bharat Mediratta 8ca573741e Indentation fixes. 2009-08-28 10:48:53 -07:00
Bharat Mediratta 47fd2dc65e Clean up in preparation for some refactoring. 2009-08-28 09:53:54 -07:00
Bharat Mediratta 98361e7613 Add a @todo to defer loading the script/css to the organize dialog. 2009-08-28 09:25:29 -07:00
Bharat Mediratta 83e850bc33 Minor style fixes. 2009-08-28 09:19:20 -07:00
Bharat Mediratta e8a3fe97a4 Fix whitespace. 2009-08-28 09:09:33 -07:00
Bharat Mediratta 7c5275a63c Fix indentation. 2009-08-28 09:08:39 -07:00
Tim Almdal 82edd2a37b This patch adds some security to the organize dialog.
1) If images are dragged from the content pane and dropped on a branch in the
   tree that the user only has view priviledges, then the drop is cancelled
   and the images are reverted.
2) The user cannot click on a branch, to which they only have view priviledges,
   the content pane does not change to the new album
2009-08-17 19:52:40 -07:00
Tim Almdal 6f6d5b306b remove the batch start/stop and replace the ORM update of the weight, with a direct sql update. This bypasses the gallery3 event mechanism. Fire a album_rearrange event when the rearrangement is complete 2009-08-17 12:56:05 -07:00
Tim Almdal 69d1b16818 Change back to using the ORM to update the child weight, but use the batch::start() method so notifications are queued 2009-08-17 12:32:33 -07:00
Tim Almdal 5e9c602b09 Fix the performance problem related to setting the child weight, by bypassing ORM and generating the sql directly. 2009-08-17 11:46:10 -07:00
Tim Almdal dd9f4b6d7f The rearrange functionality works. but it is slower than shit. I've left the debug statements in until we can solve this issue. 2009-08-17 08:49:37 -07:00
Tim Almdal 5f546050d1 The progress bar appears during a move. Still having an issue with unable to do a single select after a drop operation. I think its related to needing to destroy the existing selectable before creating the new one. The error I get is "this._selection[i].data("selectabe-item") is undefined." 2009-08-16 16:20:43 -07:00
Tim Almdal 76f320ab3d In this patch, drag now works to the album tree, but the progress bar is not
showing. As well fixed a problem where selectable single clink no longer
worked when the album was reloaded.
2009-08-16 12:36:14 -07:00
Tim Almdal eeae2dc56c Added javascript portion of the drop functionality. At this point you can drag selected images and drop them on the micro thumb grid in a different position or onto a branch in the gallery tree. No ajax call is made, it just writes the generated url and post data to the console, so it only works in ff right now. 2009-08-13 21:31:20 -07:00