Changeset 12108

Show
Ignore:
Timestamp:
09/10/07 16:07:38 (1 year ago)
Author:
rambo
Message:

basic code for listing applications for codes for a device

Files:

Legend:

Unmodified
Added
Removed
Modified
Copied
Moved
  • branches/MidCOM_2_8/org.maemo.devcodes/handler/device/view.php

    r12107 r12108  
    6161            MIDCOM_TOOLBAR_LABEL => $this->_l10n_midcom->get('list codes'), 
    6262            MIDCOM_TOOLBAR_ICON => 'stock-icons/16x16/printer.png', 
    63             MIDCOM_TOOLBAR_ACCESSKEY => 'l', 
    6463            MIDCOM_TOOLBAR_ENABLED => $this->_device->can_do('midgard:read'), 
    6564        )); 
     
    7271            MIDCOM_TOOLBAR_ENABLED => $this->_device->can_do('midgard:create'), 
    7372        )); 
     73 
     74        $this->_view_toolbar->add_item(Array( 
     75            MIDCOM_TOOLBAR_URL => "application/list/{$this->_device->guid}.html", 
     76            MIDCOM_TOOLBAR_LABEL => $this->_l10n_midcom->get('list code applications'), 
     77            MIDCOM_TOOLBAR_ICON => 'stock-icons/16x16/printer.png', 
     78            MIDCOM_TOOLBAR_ENABLED => $this->_device->can_do('midgard:read'), 
     79        )); 
     80 
    7481    } 
    7582 
  • branches/MidCOM_2_8/org.maemo.devcodes/viewer.php

    r12107 r12108  
    148148            'variable_args' => 1, 
    149149            'handler' => Array('org_maemo_devcodes_handler_application_admin', 'delete'), 
     150        ); 
     151 
     152        // Handle /application/list/<device_guid> 
     153        $this->_request_switch['list-applications'] = array 
     154        ( 
     155            'fixed_args' => Array('application', 'list'), 
     156            'variable_args' => 1, 
     157            'handler' => Array('org_maemo_devcodes_handler_application_list', 'list'), 
    150158        ); 
    151159