Changeset 801

Show
Ignore:
Timestamp:
11/21/2007 11:41:57 AM (3 years ago)
Author:
OlivierBorowski
Message:

Enable basic actions helper, refs #584

Location:
trunk/3rdparty/plugins/wikkaedit
Files:
1 added
3 modified

Legend:

Unmodified
Added
Removed
  • trunk/3rdparty/plugins/wikkaedit/wikkaedit.js

    r797 r801  
    3939        if (this.we_actionsMenuEnabled) 
    4040                this.initActions(); 
    41          
     41 
    4242        //var we_ta_container = this.we_ta;             // without textarea_container (old method) 
    4343        var we_ta_container = document.getElementById("textarea_container");    // with textarea_container 
    44          
     44 
    4545        // add a toolbar before textarea 
    4646        this.we_toolbar = document.createElement("div"); 
     
    175175        // ========== actions ========== 
    176176        if (this.we_actionsMenuEnabled) { 
    177                 html += "<div style='border-top:1px solid #CCCCCC; margin:1px 0 4px 0'></div>"; 
    178                 html += "<span style='vertical-align:middle;margin-left:5px'>Actions :</span>"; 
     177                html += "<div class='toolhorizsep'></div>"; 
     178                html += "<span class='actiontitle'>Actions :</span>"; 
    179179                for(i in this.we_categs) { 
    180180                        if (this.we_categs[i].title != null)    // hidden actions don't have a title 
     
    264264                // === use actions data to insert the action === 
    265265                // add the action and default parameters to the textarea 
    266                 var actionName = this.we_actions[actionRef].name; 
     266                var actionName = this.we_actions[actionRef].we_name; 
    267267                var OP; 
    268268                actionAndParams += "{{" + actionName; 
    269                 for(var i in this.we_actions[actionRef].params) { 
    270                         OP = this.we_actions[actionRef].params[i]; 
     269                for(var i in this.we_actions[actionRef].we_params) { 
     270                        OP = this.we_actions[actionRef].we_params[i]; 
    271271                        if ((OP.nodefault == null) || (OP.nodefault == false))  // null or hide => add param 
    272272                                actionAndParams += " " + OP.name + "=\"" + OP.value + "\""; 
     
    357357                } else { 
    358358                        for(i in this.we_actions) { 
    359                                 if (this.we_actions[i].categ == newSubmenu) { 
    360                                         html += "<div class=\"smbutton\" onclick=\"varWikkaEdit.toolbarActionClick('" + i + "');\"" + (this.we_actions[i].summary == null ? "" : " title=\"" + this.we_actions[i].summary + "\"") + ">"; 
    361                                         html += "<img class=\"smimage\" src=\"3rdparty/plugins/wikkaedit/images/" + this.we_actions[i].name + ".gif\" alt=\"" + this.we_actions[i].name + "\"" + ie6_hover + " />"; 
    362                                         html += this.we_actions[i].title; 
     359                                if (this.we_actions[i].we_categ == newSubmenu) { 
     360                                        html += "<div class=\"smbutton\" onclick=\"varWikkaEdit.toolbarActionClick('" + i + "');\"" + (this.we_actions[i].we_summary == null ? "" : " title=\"" + this.we_actions[i].we_summary + "\"") + ">"; 
     361                                        html += "<img class=\"smimage\" src=\"3rdparty/plugins/wikkaedit/images/actions/" + this.we_actions[i].we_name + ".gif\" alt=\"" + this.we_actions[i].we_name + "\"" + ie6_hover + " />"; 
     362                                        html += this.we_actions[i].we_title; 
    363363                                        html += "</div>"; 
    364364                                } 
  • trunk/3rdparty/plugins/wikkaedit/wikkaedit_data.js

    r797 r801  
    148148WikkaAction.prototype.addParam = function(name, value, nodefault, description) { 
    149149        nodefault = (nodefault == true); 
    150         this.we_params[this.nameToRef(name)] = {name:name, value:value, nodefault:nodefault, description:description}; 
     150        this.we_params[varWikkaEdit.nameToRef(name)] = {name:name, value:value, nodefault:nodefault, description:description}; 
    151151} 
    152152 
  • trunk/3rdparty/plugins/wikkaedit/wikkaedit_search.js

    r797 r801  
    55// supported browsers : MZ1.4+, MSIE5+, Opera 8+, khtml/webkit        // 
    66//                                                                    // 
    7 // Copyright (C) 2007 Olivier Borowski (coin at tuxfamily dot org)    // 
     7// (C) 2007 Olivier Borowski (olivier.borowski@wikkawiki.org)         // 
    88// Homepage : http://wikkawiki.org/WikkaEdit                          // 
    99//                                                                    //