Miles Crawford > Solstice > Solstice::Button

Download:
Solstice-1440.tar.gz

Dependencies

Annotate this POD

CPAN RT

Open  0
Report a bug
Module Version: 3370   Source  

NAME ^

Solstice::Button - A model to hold the data for a Solstice button.

SYNOPSIS ^

  use Solstice::ButtonService;
  use Solstice::Button;

  my $button = $button_service->makeButton(...);

  #The public methods in Button are for converting the Button data into an HTML 
  string...
  my $html = $button->getButton();
  $html = $button->getTextLink();
  $html = $button->getImageLink();
  $html = $button->getImageTextLink();
  $html = $button->getDropDown();
  $html = $button->getPseudoButton();

DESCRIPTION ^

The Button object is designed to be a flexible way of allowing a user to engage with the solstice framework, without the programmer needing to make sure that what they do is compatable with state processing. It was originally designed to make buttons, hence the name, but quickly grew into a tool to manage any sort of user submission to the system.

Superclass

Solstice::View

Export

No symbols exported.

Methods

new()

Constructor, sets the default button template.

getHTML()

Legacy method, use getButton() instead.

getButton()
getTextLink()
getImageLink()

Returns HTML for an image link.

getImageTextLink()

Return HTML for a combination image/text link.

getPseudoButton()

Returns HTML for a "clickable" block element.

getDropDown()

Returns HTML for a dropdown that will submit on select.

getNoscriptButton()
getNoscriptImage()
setIsIllegal()

Used by Session code - if this button is used in an expired session this is called in order to render it null and void to any controller code that might run

addAttribute(key, value)

Takes a key, value and store it into the buttons attribute hash

removeAttribute(key)

Deletes the value by the specified key

Private Methods

_generateLabel()
_generateTitle()
_generateScriptLabel()
_generateHandler()
_generateScriptTitle()
_generateTooltip()
_generateInlineScript()
_getAccessorDefinition()

Modules Used

Solstice::Model, StringLibrary.

AUTHOR ^

Catalyst Group, <catalyst@u.washington.edu>

VERSION ^

$Revision: 3370 $

COPYRIGHT ^

Copyright 1998-2007 Office of Learning Technologies, University of Washington

Licensed under the Educational Community License, Version 1.0 (the "License"); you may not use this file except in compliance with the License. You may obtain a copy of the License at: http://www.opensource.org/licenses/ecl1.php

Unless required by applicable law or agreed to in writing, software distributed under the License is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the License for the specific language governing permissions and limitations under the License.