# This patch file was generated by NetBeans IDE # This patch can be applied using context Tools: Apply Diff Patch action on respective folder. # It uses platform neutral UTF-8 encoding. # Above lines and this line are ignored by the patching process. --- administrator/components/com_comprofiler/toolbar.comprofiler.html.php +++ administrator/components/com_comprofiler/toolbar.comprofiler.html.php @@ -279,6 +279,27 @@ } /** + * Writes a common 'copy' button for a list of records + * @param string An override for the task + * @param string An override for the alt text + */ + static function copyList( $task='edit', $alt=null ) { + $listprompt = CBTxt::T('Please select an item from the list to copy'); + CBtoolmenuBar::addToToolBar($task, $alt, 'Copy', 'copy', false, $listprompt); // CBTxt::T("....") done in addToToolBar + } + + /** + * Writes a common 'copy' button for a list of records. + * Extended version of copyList() calling hideMainMenu() before submitbutton(). + * @param string An override for the task + * @param string An override for the alt text + */ + static function copyListX( $task='edit', $alt=null ) { + $listprompt = CBTxt::T('Please select an item from the list to copy'); + CBtoolmenuBar::addToToolBar($task, $alt, 'Copy', 'copy', true, $listprompt); // CBTxt::T("....") done in addToToolBar + } + + /** * Writes a common 'delete' button for a list of records * @param string Postscript for the 'are you sure' message * @param string An override for the task @@ -617,6 +638,7 @@ static function _DEFAULT_FIELD() { CBtoolmenuBar::startTable(); CBtoolmenuBar::custom( 'newField', 'new.png', 'new_f2.png', 'New Field', false ); + CBtoolmenuBar::copyList('copyField'); \ No newline at end of file CBtoolmenuBar::editList('editField'); CBtoolmenuBar::deleteList( CBTxt::T('The Field and all user data associated to this field will be lost and this cannot be undone!'), 'removeField'); CBtoolmenuBar::spacer();