[Jifty-commit] r3618 - in jifty/branches/trimclient: . lib lib/Jifty lib/Jifty/Action/Record lib/Jifty/Event lib/Jifty/Manual lib/Jifty/Mason lib/Jifty/Model lib/Jifty/Module lib/Jifty/Plugin/Authentication lib/Jifty/Plugin/Authentication/Facebook lib/Jifty/Plugin/Authentication/Facebook/Action lib/Jifty/Plugin/Authentication/Facebook/Mixin lib/Jifty/Plugin/Authentication/Facebook/Mixin/Model lib/Jifty/Plugin/Authentication/Password lib/Jifty/Plugin/Debug lib/Jifty/Plugin/SkeletonApp lib/Jifty/Script lib/Jifty/Subs lib/Jifty/Test/WWW lib/Jifty/Upgrade lib/Jifty/View/Declare lib/Jifty/View/Static lib/Jifty/Web lib/Jifty/Web/Form/Field

jifty-commit at lists.jifty.org jifty-commit at lists.jifty.org
Sat Jul 7 16:46:08 EDT 2007


Author: clkao
Date: Sat Jul  7 16:46:06 2007
New Revision: 3618

Added:
   jifty/branches/trimclient/lib/Jifty/Plugin/Authentication/Facebook/
   jifty/branches/trimclient/lib/Jifty/Plugin/Authentication/Facebook.pm
   jifty/branches/trimclient/lib/Jifty/Plugin/Authentication/Facebook/Action/
   jifty/branches/trimclient/lib/Jifty/Plugin/Authentication/Facebook/Action/LinkFacebookUser.pm
   jifty/branches/trimclient/lib/Jifty/Plugin/Authentication/Facebook/Action/LoginFacebookUser.pm
   jifty/branches/trimclient/lib/Jifty/Plugin/Authentication/Facebook/Dispatcher.pm
   jifty/branches/trimclient/lib/Jifty/Plugin/Authentication/Facebook/Mixin/
   jifty/branches/trimclient/lib/Jifty/Plugin/Authentication/Facebook/Mixin/Model/
   jifty/branches/trimclient/lib/Jifty/Plugin/Authentication/Facebook/Mixin/Model/User.pm
   jifty/branches/trimclient/lib/Jifty/Plugin/Authentication/Facebook/View.pm
Modified:
   jifty/branches/trimclient/   (props changed)
   jifty/branches/trimclient/Makefile.PL
   jifty/branches/trimclient/lib/Jifty.pm
   jifty/branches/trimclient/lib/Jifty/Action.pm
   jifty/branches/trimclient/lib/Jifty/Action/Record/Search.pm
   jifty/branches/trimclient/lib/Jifty/ClassLoader.pm
   jifty/branches/trimclient/lib/Jifty/CurrentUser.pm
   jifty/branches/trimclient/lib/Jifty/DateTime.pm
   jifty/branches/trimclient/lib/Jifty/Event.pm
   jifty/branches/trimclient/lib/Jifty/Event/Model.pm
   jifty/branches/trimclient/lib/Jifty/Manual/Cookbook.pod
   jifty/branches/trimclient/lib/Jifty/Mason/Halo.pm
   jifty/branches/trimclient/lib/Jifty/Model/SessionCollection.pm
   jifty/branches/trimclient/lib/Jifty/Module/Pluggable.pm
   jifty/branches/trimclient/lib/Jifty/Notification.pm
   jifty/branches/trimclient/lib/Jifty/Object.pm
   jifty/branches/trimclient/lib/Jifty/Plugin/Authentication/Password.pm
   jifty/branches/trimclient/lib/Jifty/Plugin/Authentication/Password/Dispatcher.pm
   jifty/branches/trimclient/lib/Jifty/Plugin/Authentication/Password/View.pm
   jifty/branches/trimclient/lib/Jifty/Plugin/Debug.pm
   jifty/branches/trimclient/lib/Jifty/Plugin/Debug/Dispatcher.pm
   jifty/branches/trimclient/lib/Jifty/Plugin/SkeletonApp/View.pm
   jifty/branches/trimclient/lib/Jifty/Plugin/User.pm
   jifty/branches/trimclient/lib/Jifty/RightsFrom.pm
   jifty/branches/trimclient/lib/Jifty/Script.pm
   jifty/branches/trimclient/lib/Jifty/Script/Deps.pm
   jifty/branches/trimclient/lib/Jifty/Server.pm
   jifty/branches/trimclient/lib/Jifty/Subs.pm
   jifty/branches/trimclient/lib/Jifty/Subs/Render.pm
   jifty/branches/trimclient/lib/Jifty/Test/WWW/Mechanize.pm
   jifty/branches/trimclient/lib/Jifty/Upgrade.pm
   jifty/branches/trimclient/lib/Jifty/Upgrade/Internal.pm
   jifty/branches/trimclient/lib/Jifty/View/Declare/CRUD.pm
   jifty/branches/trimclient/lib/Jifty/View/Declare/CoreTemplates.pm
   jifty/branches/trimclient/lib/Jifty/View/Declare/Handler.pm
   jifty/branches/trimclient/lib/Jifty/View/Declare/Helpers.pm
   jifty/branches/trimclient/lib/Jifty/View/Declare/Page.pm
   jifty/branches/trimclient/lib/Jifty/View/Static/Handler.pm
   jifty/branches/trimclient/lib/Jifty/Web.pm
   jifty/branches/trimclient/lib/Jifty/Web/Form.pm
   jifty/branches/trimclient/lib/Jifty/Web/Form/Field/Button.pm
   jifty/branches/trimclient/lib/Jifty/Web/Form/Field/Checkbox.pm
   jifty/branches/trimclient/lib/Jifty/Web/Form/Field/Combobox.pm
   jifty/branches/trimclient/lib/Jifty/Web/Form/Field/Date.pm
   jifty/branches/trimclient/lib/Jifty/Web/Form/Field/Hidden.pm
   jifty/branches/trimclient/lib/Jifty/Web/Form/Field/InlineButton.pm
   jifty/branches/trimclient/lib/Jifty/Web/Form/Field/Password.pm
   jifty/branches/trimclient/lib/Jifty/Web/Form/Field/Radio.pm
   jifty/branches/trimclient/lib/Jifty/Web/Form/Field/ResetButton.pm
   jifty/branches/trimclient/lib/Jifty/Web/Form/Field/Select.pm
   jifty/branches/trimclient/lib/Jifty/Web/Form/Field/Text.pm
   jifty/branches/trimclient/lib/Jifty/Web/Form/Field/Textarea.pm
   jifty/branches/trimclient/lib/Jifty/Web/Form/Field/Unrendered.pm
   jifty/branches/trimclient/lib/Jifty/Web/Menu.pm
   jifty/branches/trimclient/lib/Jifty/Web/Session.pm

Log:
Merge down for trimclient.

Modified: jifty/branches/trimclient/Makefile.PL
==============================================================================
--- jifty/branches/trimclient/Makefile.PL	(original)
+++ jifty/branches/trimclient/Makefile.PL	Sat Jul  7 16:46:06 2007
@@ -134,8 +134,12 @@
         recommends('Cache::FileCache'),
         recommends('LWPx::ParanoidAgent'),
     ],
+    'Facebook Login Plugin' => [
+        -default => 0,
+        recommends('WWW::Facebook::API' => '0.3.6'),
+    ],
     'Jifty console' => [
-        -default => 1,
+        -default => 0,
         recommends('Devel::EvalContext')
     ],
 );

Modified: jifty/branches/trimclient/lib/Jifty.pm
==============================================================================
--- jifty/branches/trimclient/lib/Jifty.pm	(original)
+++ jifty/branches/trimclient/lib/Jifty.pm	Sat Jul  7 16:46:06 2007
@@ -167,9 +167,19 @@
     # Set up plugins
     my @plugins;
     my @plugins_to_load = @{Jifty->config->framework('Plugins')};
+    my $app_plugin = Jifty->app_class('Plugin');
     for (my $i = 0; my $plugin = $plugins_to_load[$i]; $i++) {
-        my $class = "Jifty::Plugin::".(keys %{$plugin})[0];
-        my %options = %{ $plugin->{(keys %{$plugin})[0]} };
+        my $plugin_name = (keys %{$plugin})[0];
+        my $class;
+        if ($plugin_name =~ /^(?:Jifty::Plugin|$app_plugin)::/) {
+            # app-specific plugins use fully qualified names, Jifty plugins may
+            $class = $plugin_name; 
+        }
+        # otherwise, assume it's a short name, qualify it
+        else {
+            $class = "Jifty::Plugin::".$plugin_name;
+        }
+        my %options = %{ $plugin->{ $plugin_name } };
         Jifty::Util->require($class);
         Jifty::ClassLoader->new(base => $class)->require;
         my $plugin_obj = $class->new(%options);

Modified: jifty/branches/trimclient/lib/Jifty/Action.pm
==============================================================================
--- jifty/branches/trimclient/lib/Jifty/Action.pm	(original)
+++ jifty/branches/trimclient/lib/Jifty/Action.pm	Sat Jul  7 16:46:06 2007
@@ -36,7 +36,7 @@
 See also L<Jifty::Action::Record> for data-oriented actions, 
 L<Jifty::Result> for how to return values from actions.
 
-See L<Jifty::Param::Schema> for more details on the declarative 
+See L<Jifty::Param::Schema> for more details on the declarative
 syntax.
 
 See L<Jifty::Manual::Actions> for examples of using actions.
@@ -57,7 +57,8 @@
 
 B<Do not call this directly>; always go through C<< Jifty->web->new_action >>! 
 
-This method constructs a new action. Subclasses who need do custom initialization should start with:
+This method constructs a new action. Subclasses who need do custom
+initialization should start with:
 
     my $class = shift;
     my $self = $class->SUPER::new(@_)
@@ -81,29 +82,20 @@
 =item arguments
 
 A hash reference of default values for the
-L<arguments|Jifty::Manual::Glossary/argument> of the action.  Defaults to
-none.
+L<arguments|Jifty::Manual::Glossary/argument> of the action.  Defaults
+to none.
 
 =item sticky_on_failure
 
 A boolean value that determines if the form fields are
-L<sticky|Jifty::Manual::Glossary/sticky> when the action fails.  Defaults to
-true.
+L<sticky|Jifty::Manual::Glossary/sticky> when the action fails.
+Defaults to true.
 
 =item sticky_on_success
 
 A boolean value that determines if the form fields are
-L<sticky|Jifty::Manual::Glossary/sticky> when the action succeeds.  Defaults
-to false.
-
-=begin private
-
-=item request_arguments
-
-A hashref of arguments passed in as part of the
-L<Jifty::Request>. Internal use only.
-
-=end private
+L<sticky|Jifty::Manual::Glossary/sticky> when the action succeeds.
+Defaults to false.
 
 =back
 
@@ -127,13 +119,16 @@
         $self->_get_current_user();
     }
 
-    if ($args{'moniker'}) {
-        $self->moniker($args{'moniker'});
-    } else {
-        $self->moniker($self->_generate_moniker);
-    }
+    $self->moniker($args{'moniker'} || $self->_generate_moniker);
     $self->order($args{'order'});
 
+    my $action_in_request = Jifty->web->request->action( $self->moniker );
+    # Fields explicitly passed to new_action take precedence over those passed
+    # from the request; we read from the request to implement "sticky fields".
+    if ( $action_in_request and $action_in_request->arguments ) {
+        $args{'request_arguments'} = $action_in_request->arguments;
+    }
+
     $self->argument_values( { %{ $args{'request_arguments' } }, %{ $args{'arguments'} } } );
 
     # Keep track of whether arguments came from the request, or were
@@ -153,11 +148,12 @@
 
 =head2 _generate_moniker 
 
-Construct a moniker for a new (or soon-to-be-constructed) action that did not have
-an explicit moniker specified.  The algorithm is simple: We snapshot the call stack,
-prefix it with the action class, and then append it with an per-request autoincrement
-counter in case the same class/stack is encountered twice, which can happen if the
-programmer placed a C<new_action> call inside a loop.
+Construct a moniker for a new (or soon-to-be-constructed) action that
+did not have an explicit moniker specified.  The algorithm is simple:
+We snapshot the call stack, prefix it with the action class, and then
+append it with an per-request autoincrement counter in case the same
+class/stack is encountered twice, which can happen if the programmer
+placed a C<new_action> call inside a loop.
 
 Monikers generated this way are guaranteed to work across requests.
 
@@ -1135,9 +1131,13 @@
 
 =head2 Canonicalization
 
-If you wish to have the data in a field normalized into a particular format (such as changing a date into YYYY-MM-DD format, adding commas to numbers, capitalizing words, or whatever you need) you can do so using a canonicalizer. 
+If you wish to have the data in a field normalized into a particular
+format (such as changing a date into YYYY-MM-DD format, adding commas
+to numbers, capitalizing words, or whatever you need) you can do so
+using a canonicalizer.
 
-This is just a method titled C<canonicalize_FIELD> where C<FIELD> is the name of the field be normalized. Here is an example:
+This is just a method titled C<canonicalize_FIELD> where C<FIELD> is
+the name of the field be normalized. Here is an example:
 
   sub canonicalize_foo {
       my ($self, $value) = @_;
@@ -1148,21 +1148,28 @@
       return $normal_form;
   }
 
-In this case, all values in the "foo" field will be changed into lower case.
+In this case, all values in the "foo" field will be changed into lower
+case.
 
-While doing this you might also want to call the L</canonicalization_note> to inform the client of the modification:
+While doing this you might also want to call the
+L</canonicalization_note> to inform the client of the modification:
 
   my $normal_form = lc($value);
   $self->canonicalization_note( 
       foo => _('Foo values are always in lowercase.'));
 
-If the "foo" field has "ajax canoncalizes" set in the action schema, then this process will be performed automatically as the form is being filled without reloading the page.
+If the "foo" field has "ajax canoncalizes" set in the action schema,
+then this process will be performed automatically as the form is being
+filled without reloading the page.
 
 =head2 Validation
 
-If a value must follow a certain format, you can provide a validation method for fields to make sure that no value enters the database until it is in a valid form.
+If a value must follow a certain format, you can provide a validation
+method for fields to make sure that no value enters the database until
+it is in a valid form.
 
-A validation method is one named C<validate_FIELD> where C<FIELD> is the name of the field being checked. Here is an example:
+A validation method is one named C<validate_FIELD> where C<FIELD> is
+the name of the field being checked. Here is an example:
 
   sub validate_foo {
       my ($self, $value) = @_;
@@ -1182,15 +1189,26 @@
       return 1;
   }
 
-Here the "foo" field should not contain uppercase letters and must not contain the characters '-', '*', '+', or '?'. You can use L</validation_error> and L</validation_warning> to return the results of your validation to the user or simply return 1 to indicate a valid value.
+Here the "foo" field should not contain uppercase letters and must not
+contain the characters '-', '*', '+', or '?'. You can use
+L</validation_error> and L</validation_warning> to return the results
+of your validation to the user or simply return 1 to indicate a valid
+value.
 
-If you just have a list of valid values, you may want to use the C<valid_values> schema parameter to perform this task instead.
+If you just have a list of valid values, you may want to use the
+C<valid_values> schema parameter to perform this task instead.
 
 =head2 Autocompletion
 
-Autocompletion provides a way of suggesting choices to the client based upon partial data entry. This doesn't necessarily force the client to use one of the choices given but gives hints in an application specific way.
-
-To create an autocompletion field, you implement a method named C<autocomplete_FIELD> where C<FIELD> is the field to autocomplete. This is generally done with fields rendered as 'Text'. Here is an example:
+Autocompletion provides a way of suggesting choices to the client
+based upon partial data entry. This doesn't necessarily force the
+client to use one of the choices given but gives hints in an
+application specific way.
+
+To create an autocompletion field, you implement a method named
+C<autocomplete_FIELD> where C<FIELD> is the field to
+autocomplete. This is generally done with fields rendered as
+'Text'. Here is an example:
 
   sub autocomplete_foo {
       my ($self, $value) = @_;
@@ -1209,16 +1227,25 @@
       return map { $_->name } @{ $foos->items_array_ref };
   }
 
-In this example, the "foo" field is autocompleted from names matched from the C<MyApp::Model::Foo> table. The match, in this case, matches any substring found in the database. I could have matched any item that starts with the string, ends with the string, matches other fields than the one returned, etc. It's up to you to decide.
-
-Note also that I have untainted the value coming in to make sure a malicious user doesn't get anyway. You should always perform a check like this when data is coming in from an outside source.
-
-If you need a more complicated solution, you can return the autocompletion values as a list of hash references containing the keys C<value> and (optionally) C<label>:
+In this example, the "foo" field is autocompleted from names matched
+from the C<MyApp::Model::Foo> table. The match, in this case, matches
+any substring found in the database. I could have matched any item
+that starts with the string, ends with the string, matches other
+fields than the one returned, etc. It's up to you to decide.
+
+Note also that I have untainted the value coming in to make sure a
+malicious user doesn't get anyway. You should always perform a check
+like this when data is coming in from an outside source.
+
+If you need a more complicated solution, you can return the
+autocompletion values as a list of hash references containing the keys
+C<value> and (optionally) C<label>:
 
   return map { { value => $_->name, label => $_->label } }
             @{ $foos->items_array_ref };
 
-In this case, the labels will be shown to the client, but the selected value would be returned to your application.
+In this case, the labels will be shown to the client, but the selected
+value would be returned to your application.
 
 =cut
 
@@ -1226,7 +1253,8 @@
 
 =head1 SEE ALSO
 
-L<Jifty>, L<Jifty::API>, L<Jifty::Action::Record>, L<Jifty::Result>, L<Jifty::Param::Schema>, L<Jifty::Manual::Actions>
+L<Jifty>, L<Jifty::API>, L<Jifty::Action::Record>, L<Jifty::Result>,
+L<Jifty::Param::Schema>, L<Jifty::Manual::Actions>
 
 =head1 LICENSE
 

Modified: jifty/branches/trimclient/lib/Jifty/Action/Record/Search.pm
==============================================================================
--- jifty/branches/trimclient/lib/Jifty/Action/Record/Search.pm	(original)
+++ jifty/branches/trimclient/lib/Jifty/Action/Record/Search.pm	Sat Jul  7 16:46:06 2007
@@ -3,7 +3,7 @@
 
 =head1 NAME
 
-Jifty::Action::Record::Search
+Jifty::Action::Record::Search - Automagic search action
 
 =head1 DESCRIPTION
 

Modified: jifty/branches/trimclient/lib/Jifty/ClassLoader.pm
==============================================================================
--- jifty/branches/trimclient/lib/Jifty/ClassLoader.pm	(original)
+++ jifty/branches/trimclient/lib/Jifty/ClassLoader.pm	Sat Jul  7 16:46:06 2007
@@ -141,7 +141,7 @@
                   "package $module;\n"
                 . "use base qw/Jifty::CurrentUser/; sub _autogenerated { 1 };\n"
             );
-    } elsif ( $module =~ /^(?:$base)::Model::(\w+)Collection$/ ) {
+    } elsif ( $module =~ /^(?:$base)::Model::([^\.]+)Collection$/ ) {
         return $self->return_class(
                   "package $module;\n"
                 . "use base qw/@{[$base]}::Collection/;\n"

Modified: jifty/branches/trimclient/lib/Jifty/CurrentUser.pm
==============================================================================
--- jifty/branches/trimclient/lib/Jifty/CurrentUser.pm	(original)
+++ jifty/branches/trimclient/lib/Jifty/CurrentUser.pm	Sat Jul  7 16:46:06 2007
@@ -11,7 +11,7 @@
 
 =head1 NAME
 
-Jifty::CurrentUser
+Jifty::CurrentUser - Base class and basic implementation of current user object
 
 =head1 DESCRIPTION
 

Modified: jifty/branches/trimclient/lib/Jifty/DateTime.pm
==============================================================================
--- jifty/branches/trimclient/lib/Jifty/DateTime.pm	(original)
+++ jifty/branches/trimclient/lib/Jifty/DateTime.pm	Sat Jul  7 16:46:06 2007
@@ -60,6 +60,7 @@
 sub current_user_has_timezone {
     my $self = shift;
     $self->_get_current_user();
+    return unless $self->current_user->can('user_object');
     my $user_obj = $self->current_user->user_object or return;
     my $f = $user_obj->can('time_zone') or return;
     return $f->($user_obj);

Modified: jifty/branches/trimclient/lib/Jifty/Event.pm
==============================================================================
--- jifty/branches/trimclient/lib/Jifty/Event.pm	(original)
+++ jifty/branches/trimclient/lib/Jifty/Event.pm	Sat Jul  7 16:46:06 2007
@@ -9,7 +9,7 @@
 
 =head1 NAME
 
-Jifty::Event
+Jifty::Event - Event objects for publish/subscribe communication
 
 =head1 DESCRIPTION
 

Modified: jifty/branches/trimclient/lib/Jifty/Event/Model.pm
==============================================================================
--- jifty/branches/trimclient/lib/Jifty/Event/Model.pm	(original)
+++ jifty/branches/trimclient/lib/Jifty/Event/Model.pm	Sat Jul  7 16:46:06 2007
@@ -9,7 +9,7 @@
 
 =head1 NAME
 
-Jifty::Event::Model
+Jifty::Event::Model - Events representing changes to records
 
 =head1 DESCRIPTION
 

Modified: jifty/branches/trimclient/lib/Jifty/Manual/Cookbook.pod
==============================================================================
--- jifty/branches/trimclient/lib/Jifty/Manual/Cookbook.pod	(original)
+++ jifty/branches/trimclient/lib/Jifty/Manual/Cookbook.pod	Sat Jul  7 16:46:06 2007
@@ -1,6 +1,6 @@
 =head1 NAME
 
-Jifty::Manual::Cookbook
+Jifty::Manual::Cookbook - Recipes for common tasks in Jifty
 
 =head1 DESCRIPTION
 
@@ -482,4 +482,81 @@
 would be really cool to have access to all data of the action in
 this method, so you are welcome to post a better solution.
 
+=head2 Append a new region based upon the result of the last action using AJAX
+
+In the Administration Interface, you can create new items. You enter the information and then the newly created item is appended to the end of the list immediately without reloading the page. You can use this recipe to do something like this, or to modify the page however you need based upon the result of any server-side action.
+
+Render your action fields as you normally would. The key to the process is in the submit button. Here's how the L<Jifty::View::Declare::CRUD> does this, as of this writing:
+
+  Jifty->web->form->submit(
+      label   => 'Create',
+      onclick => [
+          { submit       => $create },
+          { refresh_self => 1 },
+          {   element =>
+                  Jifty->web->current_region->parent->get_element(
+                  'div.list'),
+              append => $self->fragment_for('view'),
+              args   => {
+                  object_type => $object_type,
+                  id => { result_of => $create, name => 'id' },
+              },
+          },
+      ]
+  );
+
+This could is embedded in a call to C<outs()> for use with L<Template::Declare> templating, but you could just as easily wrap the line above in C<< <% %> >> for use with Mason templates. The keys is each item in the list past to C<onclick>:
+
+  { submit => $create },
+
+This tells Jifty submit the form elements related to the action referenced by C<$create> only. Any other actions in the same form will be ignored.
+
+  { refresh_self => 1 },
+
+This tells the browser to refresh the current region (which will be the one containing the current submit button), so that the form can be reused. You could also modify this behavior to delete the region, if you wrote:
+
+  { delete => Jifty->web->current_region },
+
+The most complicated part is the most important:
+
+  {   element =>
+          Jifty->web->current_region->parent->get_element(
+          'div.list'),
+      append => $self->fragment_for('view'),
+      args   => {
+          object_type => $object_type,
+          id => { result_of => $create, name => 'id' },
+      },
+  },
+
+=over
+
+=item element
+
+The C<element> parameter tells the browser where to insert the new item. By using C<< Jifty->web->current_region->parent->get_element('div.list') >>, the new code will be appended to the first C<div> tag found with a C<list> class within the parent region. This assumes that you have added such an element to the parent region. 
+
+You could look up an arbitrary region using C<< Jifty->web->get_region('fully-qualified-region-name') >> if you don't want to use the parent of the current region.
+
+=item append
+
+The C<append> argument gives the path to the URL of the item to insert. By using C<append>, you are telling Jifty to add your new code to the end of the element given in C<element>. If you want to add it to the beginning, you can use C<prepend> instead.
+
+=item args
+
+Last, but not least, you need to send arguments to the URL related to the action being performed. These can be anything you need for the your template to render the required code. In this example, two arguments are passed: C<object_type> and C<id>. In the case of C<object_type> a known value is passed. In the case of C<id>, the result of the action is passed, which is the key to the whole deal:
+
+  id => { result_of => $create, name => 'id' },
+
+This line tells Jifty that you want to set the "id" paramter sent to the URL given in C<append>, to the "id" set when C<$create> is executed. That is, after running the action, Jifty will contact the URL and effectively perform:
+
+  set id => $create->result->content('id');
+
+It's a lot more complicated than that in actuality, but Jifty takes care of all the nasty details.
+
+=back
+
+If you want to use a custom action other than the built-in create and want to pass something back other than the "id", you just need to set the result into the appropriate key on the C<content> method of the L<Jifty::Result>.
+
+For more details on how you can customize this further, see L<Jifty::Manual::PageRegions>, L<Jifty::Web::Form::Element>, L<Jifty::Result>, L<Jifty::Action>, L<Jifty::Web::PageRegion>, L<Jifty::Web>, and L<Jifty::Request::Mapper>.
+
 =cut

Modified: jifty/branches/trimclient/lib/Jifty/Mason/Halo.pm
==============================================================================
--- jifty/branches/trimclient/lib/Jifty/Mason/Halo.pm	(original)
+++ jifty/branches/trimclient/lib/Jifty/Mason/Halo.pm	Sat Jul  7 16:46:06 2007
@@ -7,7 +7,7 @@
 
 =head1 NAME
 
-Jifty::Mason::Halo
+Jifty::Mason::Halo - Class for drawing "halos" around page components
 
 =head1 DESCRIPTION
 

Modified: jifty/branches/trimclient/lib/Jifty/Model/SessionCollection.pm
==============================================================================
--- jifty/branches/trimclient/lib/Jifty/Model/SessionCollection.pm	(original)
+++ jifty/branches/trimclient/lib/Jifty/Model/SessionCollection.pm	Sat Jul  7 16:46:06 2007
@@ -5,6 +5,12 @@
 
 use base qw/Jifty::Collection/;
 
+=head1 NAME
+
+Jifty::Model::SessionCollection - Specialized handling of the session collection
+
+=head2 METHODS
+
 =head2 record_class
 
 This deals with collections of L<Jifty::Model::Session>s.

Modified: jifty/branches/trimclient/lib/Jifty/Module/Pluggable.pm
==============================================================================
--- jifty/branches/trimclient/lib/Jifty/Module/Pluggable.pm	(original)
+++ jifty/branches/trimclient/lib/Jifty/Module/Pluggable.pm	Sat Jul  7 16:46:06 2007
@@ -5,7 +5,7 @@
 
 =head1 NAME
 
-Jifty::Module::Pluggable
+Jifty::Module::Pluggable - Jifty-specific helper for Module::Pluggable
 
 
 =head1 DESCRIPTION

Modified: jifty/branches/trimclient/lib/Jifty/Notification.pm
==============================================================================
--- jifty/branches/trimclient/lib/Jifty/Notification.pm	(original)
+++ jifty/branches/trimclient/lib/Jifty/Notification.pm	Sat Jul  7 16:46:06 2007
@@ -10,6 +10,10 @@
 __PACKAGE__->mk_accessors(
     qw/body preface footer subject from _recipients _to_list to/);
 
+=head1 NAME
+
+Jifty::Notification - Send emails from Jifty
+
 =head1 USAGE
 
 It is recommended that you subclass L<Jifty::Notification> and

Modified: jifty/branches/trimclient/lib/Jifty/Object.pm
==============================================================================
--- jifty/branches/trimclient/lib/Jifty/Object.pm	(original)
+++ jifty/branches/trimclient/lib/Jifty/Object.pm	Sat Jul  7 16:46:06 2007
@@ -5,7 +5,11 @@
 
 use Log::Log4perl ();
 
-=head1 Jifty::Object
+=head1 NAME
+
+Jifty::Object - Base class for most of Jifty's objects
+
+=head1 DESCRIPTION
 
 C<Jifty::Object> is the superclass of most of Jifty's objects.  It is
 used to provide convenient accessors to important global objects like
@@ -16,7 +20,7 @@
 thus, we will not define C<new> or C<_init> in C<Jifty::Object>.  We
 do assume, however, that C<$self> is a blessed hash reference.
 
-=cut
+=head1 METHODS
 
 =head2 current_user [USER]
 

Added: jifty/branches/trimclient/lib/Jifty/Plugin/Authentication/Facebook.pm
==============================================================================
--- (empty file)
+++ jifty/branches/trimclient/lib/Jifty/Plugin/Authentication/Facebook.pm	Sat Jul  7 16:46:06 2007
@@ -0,0 +1,112 @@
+use strict;
+use warnings;
+
+package Jifty::Plugin::Authentication::Facebook;
+use base qw/Jifty::Plugin/;
+
+use WWW::Facebook::API;
+
+=head1 NAME
+
+Jifty::Plugin::Authentication::Facebook
+
+=head2 DESCRIPTION
+
+Provides standalone Facebook authentication for your Jifty application.
+It adds the columns C<facebook_name>, C<facebook_uid>, C<facebook_session>,
+and C<facebook_session_expires> to your User model.
+
+=head1 SYNOPSIS
+
+In your jifty config.yml under the C<framework> section:
+
+    Plugins:
+        - Authentication::Facebook:
+            api_key: xxx
+            secret: xxx
+
+You may set any options which the C<new> method of L<WWW::Facebook::API>
+understands.
+
+In your User model, you'll need to include the line
+
+    use Jifty::Plugin::Authentication::Facebook::Mixin::Model::User;
+
+B<after> your schema definition (which may be empty).  You may also wish
+to include
+
+    sub _brief_description { 'facebook_name' }
+
+To use the user's Facebook name as their description.
+
+See L<Jifty::Plugin::Authentication::Facebook::View> for the provided templates
+and L<Jifty::Plugin::Authentication::Facebook::Dispatcher> for the URLs handled.
+
+=cut
+
+our %CONFIG = ( );
+
+=head2 init
+
+=cut
+
+sub init {
+    my $self = shift;
+    %CONFIG  = @_;
+}
+
+=head2 api
+
+Generates a new L<WWW::Facebook::API> for the current user
+
+=cut
+
+sub api {
+    my $self = shift;
+    my $api  = WWW::Facebook::API->new( %CONFIG );
+    
+    if ( Jifty->web->current_user->id ) {
+        my $user = Jifty->web->current_user->user_object;
+        $api->session(
+            uid     => $user->facebook_uid,
+            key     => $user->facebook_session,
+            expires => $user->facebook_session_expires
+        ) if $user->facebook_uid;
+    }
+
+    return $api;
+}
+
+=head2 get_login_url
+
+Gets the login URL, preserving continuations
+
+=cut
+
+sub get_login_url {
+    my $self = shift;
+    my $next = '/facebook/callback';
+ 
+    if ( Jifty->web->request->continuation ) {
+        $next .= '?J:C=' . Jifty->web->request->continuation->id;
+    }
+    return $self->api->get_login_url( next => $next );
+}
+
+=head2 get_link_url
+
+Gets the login URL used for linking, preserving continuations
+
+=cut
+
+sub get_link_url {
+    my $self = shift;
+    my $next = '/facebook/callback_link';
+ 
+    if ( Jifty->web->request->continuation ) {
+        $next .= '?J:C=' . Jifty->web->request->continuation->id;
+    }
+    return $self->api->get_login_url( next => $next );
+}
+
+1;

Added: jifty/branches/trimclient/lib/Jifty/Plugin/Authentication/Facebook/Action/LinkFacebookUser.pm
==============================================================================
--- (empty file)
+++ jifty/branches/trimclient/lib/Jifty/Plugin/Authentication/Facebook/Action/LinkFacebookUser.pm	Sat Jul  7 16:46:06 2007
@@ -0,0 +1,75 @@
+use warnings;
+use strict;
+
+=head1 NAME
+
+Jifty::Plugin::Authentication::Facebook::Action::LinkFacebookUser;
+
+=cut
+
+package Jifty::Plugin::Authentication::Facebook::Action::LinkFacebookUser;
+use base qw/Jifty::Action/;
+
+=head1 ARGUMENTS
+
+=head2 auth_token
+
+=cut
+
+use Jifty::Param::Schema;
+use Jifty::Action schema {
+    param auth_token =>
+        type is 'text',
+        is mandatory;
+};
+
+=head1 METHODS
+
+=head2 take_action
+
+Get the session key using the Facebook API.  Link to current user.
+
+=cut
+
+sub take_action {
+    my $self     = shift;
+    my ($plugin) = Jifty->find_plugin('Jifty::Plugin::Authentication::Facebook');
+    my $api      = $plugin->api;
+
+    if ( not Jifty->web->current_user->id ) {
+        $self->result->error(_("You must be logged in to link your user to your Facebook account."));
+        return;
+    }
+
+    # Get the session
+    $api->auth->get_session( $self->argument_value('auth_token') );
+
+    my $user = Jifty->web->current_user->user_object;
+
+    my $name = $api->users->get_info(
+        uids    => $api->session_uid,
+        fields  => 'name'
+    )->[0]{'name'};
+
+    # Set data
+    $user->__set( column => 'facebook_name', value => $name );
+    $user->__set( column => 'facebook_uid',  value => $api->session_uid );
+    $user->__set( column => 'facebook_session', value => $api->session_key );
+    $user->__set( column => 'facebook_session_expires', value => $api->session_expires );
+
+    # Success!
+    $self->report_success;
+
+    return 1;
+}
+
+=head2 report_success
+
+=cut
+
+sub report_success {
+    my $self = shift;
+    $self->result->message(_("Your account has been successfully linked to your Facebook user %1!", Jifty->web->current_user->user_object->facebook_name ));
+}
+
+1;

Added: jifty/branches/trimclient/lib/Jifty/Plugin/Authentication/Facebook/Action/LoginFacebookUser.pm
==============================================================================
--- (empty file)
+++ jifty/branches/trimclient/lib/Jifty/Plugin/Authentication/Facebook/Action/LoginFacebookUser.pm	Sat Jul  7 16:46:06 2007
@@ -0,0 +1,106 @@
+use warnings;
+use strict;
+
+=head1 NAME
+
+Jifty::Plugin::Authentication::Facebook::Action::LoginFacebookUser;
+
+=cut
+
+package Jifty::Plugin::Authentication::Facebook::Action::LoginFacebookUser;
+use base qw/Jifty::Action/;
+
+=head1 ARGUMENTS
+
+=head2 auth_token
+
+=cut
+
+use Jifty::Param::Schema;
+use Jifty::Action schema {
+    param auth_token =>
+        type is 'text',
+        is mandatory;
+};
+
+=head1 METHODS
+
+=head2 take_action
+
+Get the session key using the Facebook API.  Check for existing user.
+If none, autocreate.  Login user.
+
+=cut
+
+sub take_action {
+    my $self    = shift;
+    my ($plugin)  = Jifty->find_plugin('Jifty::Plugin::Authentication::Facebook');
+    my $api       = $plugin->api;
+
+    # Get the session
+    $api->auth->get_session( $self->argument_value('auth_token') );
+
+    # Load up the user
+    my $current_user = Jifty->app_class('CurrentUser');
+    my $user = $current_user->new( facebook_uid => $api->session_uid );
+
+    # Autocreate the user if necessary
+    if ( not $user->id ) {
+        my $action = Jifty->web->new_action(
+            class           => 'CreateUser',
+            current_user    => $current_user->superuser,
+            arguments       => {
+                facebook_uid     => $api->session_uid,
+                facebook_session => $api->session_key,
+                facebook_session_expires => $api->session_expires
+            }
+        );
+        $action->run;
+
+        if ( not $action->result->success ) {
+            # Should this be less "friendly"?
+            $self->result->error(_("Sorry, something weird happened (we couldn't create a user for you).  Try again later."));
+            return;
+        }
+
+        $user = $current_user->new( facebook_uid => $api->session_uid );
+    }
+
+    my $name = $api->users->get_info(
+        uids    => $api->session_uid,
+        fields  => 'name'
+    )->[0]{'name'};
+
+    my $u = $user->user_object;
+
+    # Always check name
+    $u->__set( column => 'facebook_name', value => $name )
+        if not defined $u->facebook_name or $u->facebook_name ne $name;
+
+    # Update, just in case
+    if ( $u->__value('facebook_session') ne $api->session_key ) {
+        $u->__set( column => 'facebook_session', value => $api->session_key );
+        $u->__set( column => 'facebook_session_expires', value => $api->session_expires );
+    }
+
+    # Login!
+    Jifty->web->current_user( $user );
+    Jifty->web->session->expires( (not $api->session_expires) ? '+1y' : undef );
+    Jifty->web->session->set_cookie;
+
+    # Success!
+    $self->report_success;
+
+    return 1;
+}
+
+=head2 report_success
+
+=cut
+
+sub report_success {
+    my $self = shift;
+    $self->result->message(_("Hi %1!", Jifty->web->current_user->user_object->facebook_name ));
+}
+
+1;

Added: jifty/branches/trimclient/lib/Jifty/Plugin/Authentication/Facebook/Dispatcher.pm
==============================================================================
--- (empty file)
+++ jifty/branches/trimclient/lib/Jifty/Plugin/Authentication/Facebook/Dispatcher.pm	Sat Jul  7 16:46:06 2007
@@ -0,0 +1,70 @@
+use strict;
+use warnings;
+
+package Jifty::Plugin::Authentication::Facebook::Dispatcher;
+use Jifty::Dispatcher -base;
+
+=head1 NAME
+
+Jifty::Plugin::Authentication::Facebook::Dispatcher
+
+=head1 DESCRIPTION
+
+All the dispatcher rules jifty needs to support L<Jifty::Authentication::Facebook>
+
+=head1 RULES
+
+=head2 before '/facebook/callback'
+
+Handles the login callback.  You probably don't need to worry about this.
+
+=cut
+
+before qr'^/facebook/callback(_link)?' => run {
+    my $link    = $1 ? 1 : 0;
+    my $action  = $link ? 'LinkFacebookUser' : 'LoginFacebookUser';
+    my $moniker = $link ? 'facebooklink'     : 'facebooklogin';
+
+    Jifty->web->request->add_action(
+        moniker   => $moniker,
+        class     => $action,
+        arguments => {
+            auth_token => get('auth_token'),
+        }
+    );
+    if ( Jifty->web->request->continuation ) {
+        Jifty->web->request->continuation->call;
+    }
+    else {
+        redirect '/';
+    }
+};
+
+=head2 before '/facebook/force_login'
+
+Redirects user to the Facebook login page.  Useful if you want to skip
+prompting the user to login on your app.
+
+=cut
+
+before '/facebook/force_login' => run {
+    my ($plugin) = Jifty->find_plugin('Jifty::Plugin::Authentication::Facebook');
+    Jifty->web->_redirect( $plugin->get_login_url );
+};
+
+=head2 before '/facebook/logout'
+
+Directing a user here will log him out of the app and Facebook.
+
+=cut
+
+before '/facebook/logout' => run {
+    if ( Jifty->web->current_user->id ) {
+        Jifty->web->current_user( undef );
+        my ($plugin) = Jifty->find_plugin('Jifty::Plugin::Authentication::Facebook');
+        $plugin->api->auth->logout;
+    };
+    redirect '/';
+};
+
+1;

Added: jifty/branches/trimclient/lib/Jifty/Plugin/Authentication/Facebook/Mixin/Model/User.pm
==============================================================================
--- (empty file)
+++ jifty/branches/trimclient/lib/Jifty/Plugin/Authentication/Facebook/Mixin/Model/User.pm	Sat Jul  7 16:46:06 2007
@@ -0,0 +1,39 @@
+use strict;
+use warnings;
+
+package Jifty::Plugin::Authentication::Facebook::Mixin::Model::User;
+use Jifty::DBI::Schema;
+use base 'Jifty::DBI::Record::Plugin';
+
+use Jifty::Plugin::Authentication::Facebook::Record schema {
+
+    column facebook_name => 
+        type is 'text';
+
+    column facebook_uid => 
+        type is 'int',
+        is immutable,
+        is distinct;
+
+    column facebook_session =>
+        type is 'text';
+
+    column facebook_session_expires =>
+        type is 'int';
+
+};
+
+=head2 set_facebook_uid INT
+
+Sets the user's Facebook ID
+
+=cut
+
+sub set_facebook_uid {
+    my $self = shift;
+    my $id   = shift;
+    $self->_set( column => 'facebook_uid', value => $id );
+}
+
+1;
+

Added: jifty/branches/trimclient/lib/Jifty/Plugin/Authentication/Facebook/View.pm
==============================================================================
--- (empty file)
+++ jifty/branches/trimclient/lib/Jifty/Plugin/Authentication/Facebook/View.pm	Sat Jul  7 16:46:06 2007
@@ -0,0 +1,49 @@
+use warnings;
+use strict;
+package Jifty::Plugin::Authentication::Facebook::View;
+
+use Jifty::View::Declare -base;
+
+=head1 NAME
+
+Jifty::Plugin::Authentication::Facebook::View
+
+=head1 DESCRIPTION
+
+Provides the Facebook login fragment for L<Jifty::Plugin::Authentication::Facebook>
+
+=head2 /facebook/login
+
+This fragment shows the standard Facebook button used for web login.
+
+=cut
+
+template '/facebook/login' => sub {
+    my ($plugin) = Jifty->find_plugin('Jifty::Plugin::Authentication::Facebook');
+    div {{ id is 'facebook_login' };
+        span { _("Login to Facebook now to get started!") };
+        a {{ href is $plugin->get_login_url };
+            img {{ src is 'http://static.ak.facebook.com/images/devsite/facebook_login.gif', border is '0' }};
+        };
+    };
+};
+
+=head2 /facebook/link
+
+This fragment shows the standard Facebook login button, prompting the user to
+link his account.
+
+=cut
+
+template '/facebook/link' => sub {
+    my ($plugin) = Jifty->find_plugin('Jifty::Plugin::Authentication::Facebook');
+    div {{ id is 'facebook_link' };
+        span { _("Login to Facebook now to link it with your current account!") };
+        a {{ href is $plugin->get_link_url };
+            img {{ src is 'http://static.ak.facebook.com/images/devsite/facebook_login.gif', border is '0' }};
+        };
+    };
+};
+
+
+1;

Modified: jifty/branches/trimclient/lib/Jifty/Plugin/Authentication/Password.pm
==============================================================================
--- jifty/branches/trimclient/lib/Jifty/Plugin/Authentication/Password.pm	(original)
+++ jifty/branches/trimclient/lib/Jifty/Plugin/Authentication/Password.pm	Sat Jul  7 16:46:06 2007
@@ -29,7 +29,7 @@
 
 =head1 SEE ALSO
 
-L<Jifty::Plugin::User>, L<Jifty::Plugin::LetMe>, L<Jifty::Plugin::Authentication::Password::Mixin::Model::User>
+L<Jifty::Manual::AccessControl>, L<Jifty::Plugin::User>, L<Jifty::Plugin::LetMe>, L<Jifty::Plugin::Authentication::Password::Mixin::Model::User>
 
 =head1 LICENSE
 

Modified: jifty/branches/trimclient/lib/Jifty/Plugin/Authentication/Password/Dispatcher.pm
==============================================================================
--- jifty/branches/trimclient/lib/Jifty/Plugin/Authentication/Password/Dispatcher.pm	(original)
+++ jifty/branches/trimclient/lib/Jifty/Plugin/Authentication/Password/Dispatcher.pm	Sat Jul  7 16:46:06 2007
@@ -164,5 +164,6 @@
 Jifty is Copyright 2005-2007 Best Practical Solutions, LLC.
 Jifty is distributed under the same terms as Perl itself.
 
+=cut
 
 1;

Modified: jifty/branches/trimclient/lib/Jifty/Plugin/Authentication/Password/View.pm
==============================================================================
--- jifty/branches/trimclient/lib/Jifty/Plugin/Authentication/Password/View.pm	(original)
+++ jifty/branches/trimclient/lib/Jifty/Plugin/Authentication/Password/View.pm	Sat Jul  7 16:46:06 2007
@@ -14,7 +14,7 @@
 
 Is the above really true or need to said anymore? -- Sterling
 
-=end
+=end comment
 
 This provides the templates for the pages and forms used by the password authentication plugin.
 
@@ -162,7 +162,7 @@
 
 What's the difference between lost_password and passwordreminder? -- Sterling
 
-=end
+=end comment
 
 =cut
 

Modified: jifty/branches/trimclient/lib/Jifty/Plugin/Debug.pm
==============================================================================
--- jifty/branches/trimclient/lib/Jifty/Plugin/Debug.pm	(original)
+++ jifty/branches/trimclient/lib/Jifty/Plugin/Debug.pm	Sat Jul  7 16:46:06 2007
@@ -4,4 +4,14 @@
 package Jifty::Plugin::Debug;
 use base qw/Jifty::Plugin/;
 
+=head1 NAME
+
+Jifty::Plugin::Debug - a plugin to log each incoming request
+
+=head1 DESCRIPTION
+
+Enable this plugin in your F<etc/config.yml> (requires no configuration) and the plugin add an INFO level log message on each request received. It will contain the PID of the current process, the URL requested, and the username (if any) of the person making the request.
+
+=cut
+
 1;

Modified: jifty/branches/trimclient/lib/Jifty/Plugin/Debug/Dispatcher.pm
==============================================================================
--- jifty/branches/trimclient/lib/Jifty/Plugin/Debug/Dispatcher.pm	(original)
+++ jifty/branches/trimclient/lib/Jifty/Plugin/Debug/Dispatcher.pm	Sat Jul  7 16:46:06 2007
@@ -4,6 +4,22 @@
 package Jifty::Plugin::Debug::Dispatcher;
 use Jifty::Dispatcher -base;
 
+=head1 NAME
+
+Jifty::Plugin::Debug::Dispatcher - dispatcher for the debug plugin
+
+=head1 DESCRIPTION
+
+This adds a debugging rule to record debugging information about every request.
+
+=head1 RULES
+
+=head2 on qr'(.*)'
+
+Records the request. The INFO level log message recorded contains the PID of the current process, the URL requested, and the username (if any) attached to the current session.
+
+=cut
+
 on qr'(.*)' => run {
     Jifty->log->info("[$$] $1 ".(Jifty->web->current_user->id ? Jifty->web->current_user->username : ''));
 };

Modified: jifty/branches/trimclient/lib/Jifty/Plugin/SkeletonApp/View.pm
==============================================================================
--- jifty/branches/trimclient/lib/Jifty/Plugin/SkeletonApp/View.pm	(original)
+++ jifty/branches/trimclient/lib/Jifty/Plugin/SkeletonApp/View.pm	Sat Jul  7 16:46:06 2007
@@ -15,7 +15,9 @@
 =head1 DESCRIPTION
 
 This somewhat-finished (But not quite) template library implements
-Jifty's "pony" Application. It could certainly use some refactoring. (And some of the menu stuff should get factored out into a dispatcher or the other plugins that implement it.
+Jifty's "pony" Application. It could certainly use some
+refactoring. (And some of the menu stuff should get factored out into
+a dispatcher or the other plugins that implement it.
 
 
 =cut

Modified: jifty/branches/trimclient/lib/Jifty/Plugin/User.pm
==============================================================================
--- jifty/branches/trimclient/lib/Jifty/Plugin/User.pm	(original)
+++ jifty/branches/trimclient/lib/Jifty/Plugin/User.pm	Sat Jul  7 16:46:06 2007
@@ -14,7 +14,7 @@
 
 =head1 SEE ALSO
 
-L<Jifty::Plugin::User::Mixin::Model::User>, L<Jifty::Plugin::Authentication::Password>
+L<Jifty::Manual::AccessControl>, L<Jifty::Plugin::User::Mixin::Model::User>, L<Jifty::Plugin::Authentication::Password>
 
 =head1 LICENSE
 

Modified: jifty/branches/trimclient/lib/Jifty/RightsFrom.pm
==============================================================================
--- jifty/branches/trimclient/lib/Jifty/RightsFrom.pm	(original)
+++ jifty/branches/trimclient/lib/Jifty/RightsFrom.pm	Sat Jul  7 16:46:06 2007
@@ -3,7 +3,7 @@
 
 =head1 NAME
 
-Jifty::RightsFrom
+Jifty::RightsFrom - Delegate access control to a related object
 
 =head1 SYNOPSIS
 

Modified: jifty/branches/trimclient/lib/Jifty/Script.pm
==============================================================================
--- jifty/branches/trimclient/lib/Jifty/Script.pm	(original)
+++ jifty/branches/trimclient/lib/Jifty/Script.pm	Sat Jul  7 16:46:06 2007
@@ -2,6 +2,12 @@
 use App::CLI;
 use base qw/App::CLI App::CLI::Command/;
 
+=head1 NAME
+
+Jifty::Script - Base class for all bin/jifty commands
+
+=head1 METHODS
+
 =head2 prepare
 
 C<prepare> figures out which command to run. If the user wants

Modified: jifty/branches/trimclient/lib/Jifty/Script/Deps.pm
==============================================================================
--- jifty/branches/trimclient/lib/Jifty/Script/Deps.pm	(original)
+++ jifty/branches/trimclient/lib/Jifty/Script/Deps.pm	Sat Jul  7 16:46:06 2007
@@ -12,6 +12,12 @@
 use version;
 use Jifty::Config;
 
+=head1 NAME
+
+Jifty::Script::Deps - Looks for module dependencies and attempts to install them from CPAN
+
+=head1 METHODS
+
 =head2 options
 
 Returns a hash of all the options this script takes. (See the usage message for details)

Modified: jifty/branches/trimclient/lib/Jifty/Server.pm
==============================================================================
--- jifty/branches/trimclient/lib/Jifty/Server.pm	(original)
+++ jifty/branches/trimclient/lib/Jifty/Server.pm	Sat Jul  7 16:46:06 2007
@@ -3,6 +3,10 @@
 
 package Jifty::Server;
 
+=head1 NAME
+
+Jifty::Server - Stand-alone server implementation for Jifty
+
 =head1 SYNOPSIS
 
   use Jifty::Server;

Modified: jifty/branches/trimclient/lib/Jifty/Subs.pm
==============================================================================
--- jifty/branches/trimclient/lib/Jifty/Subs.pm	(original)
+++ jifty/branches/trimclient/lib/Jifty/Subs.pm	Sat Jul  7 16:46:06 2007
@@ -8,7 +8,7 @@
 
 =head1 NAME
 
-Jifty::Subs - 
+Jifty::Subs - Configure subscriptions for the current window or session
 
 =head1 SYNOPSIS
 
@@ -27,7 +27,7 @@
 
 
 
-=cut
+=head1 METHODS
 
 =head2 add PARAMHASH
 

Modified: jifty/branches/trimclient/lib/Jifty/Subs/Render.pm
==============================================================================
--- jifty/branches/trimclient/lib/Jifty/Subs/Render.pm	(original)
+++ jifty/branches/trimclient/lib/Jifty/Subs/Render.pm	Sat Jul  7 16:46:06 2007
@@ -4,7 +4,7 @@
 
 =head1 NAME
 
-Jifty::Subs::Render - 
+Jifty::Subs::Render - Helper for subscriptions rendering
 
 =head1 SYNOPSIS
 

Modified: jifty/branches/trimclient/lib/Jifty/Test/WWW/Mechanize.pm
==============================================================================
--- jifty/branches/trimclient/lib/Jifty/Test/WWW/Mechanize.pm	(original)
+++ jifty/branches/trimclient/lib/Jifty/Test/WWW/Mechanize.pm	Sat Jul  7 16:46:06 2007
@@ -436,7 +436,10 @@
 sub session {
     my $self = shift;
 
-    return undef unless $self->cookie_jar->as_string =~ /JIFTY_SID_\d+=([^;]+)/;
+    my $cookie = Jifty->config->framework('Web')->{'SessionCookieName'};
+    $cookie =~ s/\$PORT/(?:\\d+|NOPORT)/g;
+
+    return undef unless $self->cookie_jar->as_string =~ /$cookie=([^;]+)/;
 
     my $session = Jifty::Web::Session->new;
     $session->load($1);

Modified: jifty/branches/trimclient/lib/Jifty/Upgrade.pm
==============================================================================
--- jifty/branches/trimclient/lib/Jifty/Upgrade.pm	(original)
+++ jifty/branches/trimclient/lib/Jifty/Upgrade.pm	Sat Jul  7 16:46:06 2007
@@ -3,7 +3,7 @@
 
 =head1 NAME
 
-Jifty::Upgrade
+Jifty::Upgrade - Superclass for schema/data upgrades to Jifty applicaitons
 
 =head1 DESCRIPTION
 

Modified: jifty/branches/trimclient/lib/Jifty/Upgrade/Internal.pm
==============================================================================
--- jifty/branches/trimclient/lib/Jifty/Upgrade/Internal.pm	(original)
+++ jifty/branches/trimclient/lib/Jifty/Upgrade/Internal.pm	Sat Jul  7 16:46:06 2007
@@ -9,6 +9,12 @@
 # XXX TODO: there's probably a cleaner way to cope than "INITIAL_VERSION", perhaps using ->VERSIONS
 our $INITIAL_VERSION;
 
+=head1 NAME
+
+Jifty::Upgrade::Internal - Upgrades to Jifty-specific schemas and data
+
+=head1 UPGRADES
+
 =head2 Version 0.60427
 
 Version metadata, previously stored in _db_version, get migrated to

Modified: jifty/branches/trimclient/lib/Jifty/View/Declare/CRUD.pm
==============================================================================
--- jifty/branches/trimclient/lib/Jifty/View/Declare/CRUD.pm	(original)
+++ jifty/branches/trimclient/lib/Jifty/View/Declare/CRUD.pm	Sat Jul  7 16:46:06 2007
@@ -19,7 +19,9 @@
 
 =head1 DESCRIPTION
 
-This class provides a set of views that may be used by a model to display Create/Read/Update/Delete views using the L<Template::Declare> templating langauge.
+This class provides a set of views that may be used by a model to
+display Create/Read/Update/Delete views using the L<Template::Declare>
+templating langauge.
 
 =head1 METHODS
 

Modified: jifty/branches/trimclient/lib/Jifty/View/Declare/CoreTemplates.pm
==============================================================================
--- jifty/branches/trimclient/lib/Jifty/View/Declare/CoreTemplates.pm	(original)
+++ jifty/branches/trimclient/lib/Jifty/View/Declare/CoreTemplates.pm	Sat Jul  7 16:46:06 2007
@@ -9,7 +9,7 @@
 
 =head1 NAME 
 
-Jifty::View::Declare::CoreTemplates
+Jifty::View::Declare::CoreTemplates - Templates Jifty can't function without
 
 =head1 DESCRIPTION
 

Modified: jifty/branches/trimclient/lib/Jifty/View/Declare/Handler.pm
==============================================================================
--- jifty/branches/trimclient/lib/Jifty/View/Declare/Handler.pm	(original)
+++ jifty/branches/trimclient/lib/Jifty/View/Declare/Handler.pm	Sat Jul  7 16:46:06 2007
@@ -10,7 +10,7 @@
 
 =head1 NAME
 
-Jifty::View::Declare::Handler
+Jifty::View::Declare::Handler - The Jifty view handler for Template::Declare
 
 =head1 METHODS
 

Modified: jifty/branches/trimclient/lib/Jifty/View/Declare/Helpers.pm
==============================================================================
--- jifty/branches/trimclient/lib/Jifty/View/Declare/Helpers.pm	(original)
+++ jifty/branches/trimclient/lib/Jifty/View/Declare/Helpers.pm	Sat Jul  7 16:46:06 2007
@@ -9,7 +9,7 @@
 
 =head1 NAME
 
-Jifty::View::Declare::Helpers
+Jifty::View::Declare::Helpers - Additional subroutines for Jifty TD templates
 
 =head1 DESCRIPTION
 

Modified: jifty/branches/trimclient/lib/Jifty/View/Declare/Page.pm
==============================================================================
--- jifty/branches/trimclient/lib/Jifty/View/Declare/Page.pm	(original)
+++ jifty/branches/trimclient/lib/Jifty/View/Declare/Page.pm	Sat Jul  7 16:46:06 2007
@@ -49,8 +49,8 @@
 
     Template::Declare->new_buffer_frame;
     outs_raw(
-        '<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">'
-      . '<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en">' );
+        '<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">' . "\n"
+      . '<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en">' . "\n" );
 
     $self->_render_header($self->_title || Jifty->config->framework('ApplicationName'));
 

Modified: jifty/branches/trimclient/lib/Jifty/View/Static/Handler.pm
==============================================================================
--- jifty/branches/trimclient/lib/Jifty/View/Static/Handler.pm	(original)
+++ jifty/branches/trimclient/lib/Jifty/View/Static/Handler.pm	Sat Jul  7 16:46:06 2007
@@ -14,7 +14,7 @@
 
 =head1 NAME
 
-Jifty::View::Static::Handler
+Jifty::View::Static::Handler - Jifty view handler for static files
 
 head1 DESCRIPTION
 

Modified: jifty/branches/trimclient/lib/Jifty/Web.pm
==============================================================================
--- jifty/branches/trimclient/lib/Jifty/Web.pm	(original)
+++ jifty/branches/trimclient/lib/Jifty/Web.pm	Sat Jul  7 16:46:06 2007
@@ -457,7 +457,9 @@
 
 =head3 new_action class => CLASS, moniker => MONIKER, order => ORDER, arguments => PARAMHASH
 
-Creates a new action (an instance of a subclass of L<Jifty::Action>). The named arguments passed to this method are passed on to the C<new> method of the action named in C<CLASS>.
+Creates a new action (an instance of a subclass of
+L<Jifty::Action>). The named arguments passed to this method are
+passed on to the C<new> method of the action named in C<CLASS>.
 
 =head3 Arguments
 
@@ -522,17 +524,6 @@
     $class = Jifty->api->qualify($class);
 
     my $loaded = Jifty::Util->require( $class );
-    $args{moniker} ||= ($loaded ? $class : 'Jifty::Action')->_generate_moniker;
-
-    my $action_in_request = $self->request->action( $args{moniker} );
-
-    # Fields explicitly passed to new_action take precedence over those passed
-    # from the request; we read from the request to implement "sticky fields".
-    #
-    if ( $action_in_request and $action_in_request->arguments ) {
-        $args{'request_arguments'} = $action_in_request->arguments;
-    }
-
     # The implementation class is provided by the client, so this
     # isn't a "shouldn't happen"
     return unless $loaded;

Modified: jifty/branches/trimclient/lib/Jifty/Web/Form.pm
==============================================================================
--- jifty/branches/trimclient/lib/Jifty/Web/Form.pm	(original)
+++ jifty/branches/trimclient/lib/Jifty/Web/Form.pm	Sat Jul  7 16:46:06 2007
@@ -7,6 +7,12 @@
 
 __PACKAGE__->mk_accessors(qw(actions printed_actions name call is_open disable_autocomplete target submit_to));
 
+=head1 NAME
+
+Jifty::Web::Form - Tools for rendering and dealing with HTML forms
+
+=head1 METHODS
+
 =head2 new ARGS
 
 Creates a new L<Jifty::Web::Form>.  Arguments:

Modified: jifty/branches/trimclient/lib/Jifty/Web/Form/Field/Button.pm
==============================================================================
--- jifty/branches/trimclient/lib/Jifty/Web/Form/Field/Button.pm	(original)
+++ jifty/branches/trimclient/lib/Jifty/Web/Form/Field/Button.pm	Sat Jul  7 16:46:06 2007
@@ -9,7 +9,7 @@
 
 =head1 NAME
 
-Jifty::Web::Form::Field::Button
+Jifty::Web::Form::Field::Button - Add buttons to your forms
 
 =cut
 

Modified: jifty/branches/trimclient/lib/Jifty/Web/Form/Field/Checkbox.pm
==============================================================================
--- jifty/branches/trimclient/lib/Jifty/Web/Form/Field/Checkbox.pm	(original)
+++ jifty/branches/trimclient/lib/Jifty/Web/Form/Field/Checkbox.pm	Sat Jul  7 16:46:06 2007
@@ -6,6 +6,12 @@
 use base qw/Jifty::Web::Form::Field/;
 __PACKAGE__->mk_accessors(qw/checked value/);
 
+=head1 NAME
+
+Jifty::Web::Form::Field::Checkbox - Add checkboxes to your forms
+
+=head1 METHODS
+
 =head2 accessors
 
 Provide C<checked> and C<value> accessors, in addition to

Modified: jifty/branches/trimclient/lib/Jifty/Web/Form/Field/Combobox.pm
==============================================================================
--- jifty/branches/trimclient/lib/Jifty/Web/Form/Field/Combobox.pm	(original)
+++ jifty/branches/trimclient/lib/Jifty/Web/Form/Field/Combobox.pm	Sat Jul  7 16:46:06 2007
@@ -5,6 +5,12 @@
 
 use base qw/Jifty::Web::Form::Field/;
 
+=head1 NAME
+
+Jifty::Web::Form::Field::Combobox - Add comboboxes to your forms
+
+=head1 METHODS
+
 =head2 render_widget
 
 Renders the select widget.

Modified: jifty/branches/trimclient/lib/Jifty/Web/Form/Field/Date.pm
==============================================================================
--- jifty/branches/trimclient/lib/Jifty/Web/Form/Field/Date.pm	(original)
+++ jifty/branches/trimclient/lib/Jifty/Web/Form/Field/Date.pm	Sat Jul  7 16:46:06 2007
@@ -5,6 +5,12 @@
 
 use base qw/Jifty::Web::Form::Field/;
 
+=head1 NAME
+
+Jifty::Web::Form::Field::Date - Add date pickers to your forms
+
+=head1 METHODS
+
 =head2 classes
 
 Output date fields with the class 'date'

Modified: jifty/branches/trimclient/lib/Jifty/Web/Form/Field/Hidden.pm
==============================================================================
--- jifty/branches/trimclient/lib/Jifty/Web/Form/Field/Hidden.pm	(original)
+++ jifty/branches/trimclient/lib/Jifty/Web/Form/Field/Hidden.pm	Sat Jul  7 16:46:06 2007
@@ -5,6 +5,12 @@
 
 use base qw/Jifty::Web::Form::Field/;
 
+=head1 NAME
+
+Jifty::Web::Form::Field::Hidden - Add hidden fields to your forms
+
+=head1 METHODS
+
 =head2 type
 
 The HTML input type is C<hidden>.

Modified: jifty/branches/trimclient/lib/Jifty/Web/Form/Field/InlineButton.pm
==============================================================================
--- jifty/branches/trimclient/lib/Jifty/Web/Form/Field/InlineButton.pm	(original)
+++ jifty/branches/trimclient/lib/Jifty/Web/Form/Field/InlineButton.pm	Sat Jul  7 16:46:06 2007
@@ -5,6 +5,11 @@
 
 use base qw/Jifty::Web::Form::Field::Button/;
 
+=head1 NAME
+
+Jifty::Web::Form::Field::InlineButton - Add buttons without a form
+
+=head1 METHODS
 
 =head2 render
 

Modified: jifty/branches/trimclient/lib/Jifty/Web/Form/Field/Password.pm
==============================================================================
--- jifty/branches/trimclient/lib/Jifty/Web/Form/Field/Password.pm	(original)
+++ jifty/branches/trimclient/lib/Jifty/Web/Form/Field/Password.pm	Sat Jul  7 16:46:06 2007
@@ -5,6 +5,12 @@
 
 use base qw/Jifty::Web::Form::Field/;
 
+=head1 NAME
+
+Jifty::Web::Form::Field::Password - Add a password field to your forms
+
+=head1 METHODS
+
 =head2 type
 
 The HTML input type is C<password>.

Modified: jifty/branches/trimclient/lib/Jifty/Web/Form/Field/Radio.pm
==============================================================================
--- jifty/branches/trimclient/lib/Jifty/Web/Form/Field/Radio.pm	(original)
+++ jifty/branches/trimclient/lib/Jifty/Web/Form/Field/Radio.pm	Sat Jul  7 16:46:06 2007
@@ -5,6 +5,12 @@
 
 use base qw/Jifty::Web::Form::Field/;
 
+=head1 NAME
+
+Jifty::Web::Form::Field::Radio - Add a radio button to your forms
+
+=head1 METHODS
+
 =head2 render_widget
 
 Renders the whole radio button collection.

Modified: jifty/branches/trimclient/lib/Jifty/Web/Form/Field/ResetButton.pm
==============================================================================
--- jifty/branches/trimclient/lib/Jifty/Web/Form/Field/ResetButton.pm	(original)
+++ jifty/branches/trimclient/lib/Jifty/Web/Form/Field/ResetButton.pm	Sat Jul  7 16:46:06 2007
@@ -5,6 +5,11 @@
 
 use base qw/Jifty::Web::Form::Field::InlineButton/;
 
+=head1 NAME
+
+Jifty::Web::Form::Field::ResetButton - Add a reset button to your forms
+
+=head1 METHODS
 
 =head2 render_widget
 

Modified: jifty/branches/trimclient/lib/Jifty/Web/Form/Field/Select.pm
==============================================================================
--- jifty/branches/trimclient/lib/Jifty/Web/Form/Field/Select.pm	(original)
+++ jifty/branches/trimclient/lib/Jifty/Web/Form/Field/Select.pm	Sat Jul  7 16:46:06 2007
@@ -5,6 +5,12 @@
 
 use base qw/Jifty::Web::Form::Field/;
 
+=head1 NAME
+
+Jifty::Web::Form::Field::Select - Add a list/popup menu control to your forms
+
+=head1 METHODS
+
 =head2 render_widget
 
 Renders the select widget.

Modified: jifty/branches/trimclient/lib/Jifty/Web/Form/Field/Text.pm
==============================================================================
--- jifty/branches/trimclient/lib/Jifty/Web/Form/Field/Text.pm	(original)
+++ jifty/branches/trimclient/lib/Jifty/Web/Form/Field/Text.pm	Sat Jul  7 16:46:06 2007
@@ -8,6 +8,8 @@
 
 Jifty::Web::Form::Field::Text - Renders as a small text field
 
+=head1 METHODS
+
 =cut
 
 our $VERSION = 1;

Modified: jifty/branches/trimclient/lib/Jifty/Web/Form/Field/Textarea.pm
==============================================================================
--- jifty/branches/trimclient/lib/Jifty/Web/Form/Field/Textarea.pm	(original)
+++ jifty/branches/trimclient/lib/Jifty/Web/Form/Field/Textarea.pm	Sat Jul  7 16:46:06 2007
@@ -7,6 +7,12 @@
 
 __PACKAGE__->mk_accessors(qw(rows cols));
 
+=head1 NAME
+
+Jifty::Web::Form::Field::Textarea - Add a multiline text field to your forms
+
+=head1 METHODS
+
 =head2 accessors
 
 Provide C<rows> and C<cols> accessors, in addition to

Modified: jifty/branches/trimclient/lib/Jifty/Web/Form/Field/Unrendered.pm
==============================================================================
--- jifty/branches/trimclient/lib/Jifty/Web/Form/Field/Unrendered.pm	(original)
+++ jifty/branches/trimclient/lib/Jifty/Web/Form/Field/Unrendered.pm	Sat Jul  7 16:46:06 2007
@@ -5,6 +5,12 @@
 
 use base qw/Jifty::Web::Form::Field/;
 
+=head1 NAME
+
+Jifty::Web::Form::Field::Unrendered - Handle unrendered fields
+
+=head1 METHODS
+
 =head2 render
 
 Don't render anything. For one reason or another, this form field should never, ever be rendered, perhaps

Modified: jifty/branches/trimclient/lib/Jifty/Web/Menu.pm
==============================================================================
--- jifty/branches/trimclient/lib/Jifty/Web/Menu.pm	(original)
+++ jifty/branches/trimclient/lib/Jifty/Web/Menu.pm	Sat Jul  7 16:46:06 2007
@@ -6,6 +6,12 @@
 
 __PACKAGE__->mk_accessors(qw(label parent sort_order link target escape_label class));
 
+=head1 NAME
+
+Jifty::Web::Menu - Handle the API for menu navigation
+
+=head1 METHODS
+
 =head2 new PARAMHASH
 
 Creates a new L<Jifty::Web::Menu> object.  Possible keys in the

Modified: jifty/branches/trimclient/lib/Jifty/Web/Session.pm
==============================================================================
--- jifty/branches/trimclient/lib/Jifty/Web/Session.pm	(original)
+++ jifty/branches/trimclient/lib/Jifty/Web/Session.pm	Sat Jul  7 16:46:06 2007
@@ -284,8 +284,6 @@
 
     my $cookie_name = $self->cookie_name;
     my %cookies     = CGI::Cookie->fetch();
-    my $session_id
-        = $cookies{$cookie_name} ? $cookies{$cookie_name}->value() : undef;
     my $cookie = new CGI::Cookie(
         -name    => $cookie_name,
         -value   => $self->id,


More information about the Jifty-commit mailing list