Roxen.git / server / etc / modules / Variable.pmod / module.pmod

version» Context lines:

Roxen.git/server/etc/modules/Variable.pmod/module.pmod:1078:   {    inherit String;    constant type = "Text";       int cols = 56;    //! The width of the textarea       int rows = 10;    //! The height of the textarea    +  bool wrap = false; +  //! Allow text wrapping +     string diff( int render )    {    switch( render )    {    case 0: return 0;    case 1: return "";    case 2:    array lines_orig = default_value()/"\n";    array lines_new = query()/"\n";   
Roxen.git/server/etc/modules/Variable.pmod/module.pmod:1104:    }    }       array(string) verify_set_from_form( mixed new )    {    return ({ 0, [string]new-"\r" });    }       string render_form( RequestID id, void|mapping additional_args )    { -  return "<textarea cols='"+cols+"' rows='"+rows+"' name='"+path()+"' wrap='off'>" +  return "<textarea cols='"+cols+"' rows='"+rows+"' name='"+path()+"' " + +  (wrap ? "style='word-break: break-all'" : "wrap='off'") + ">"    + Roxen.html_encode_string( query() || "" ) +    "</textarea>";    }       protected void create(mixed default_value, void|int flags,    void|LocaleString std_name, void|LocaleString std_doc)    //! Constructor.    //! Flags is a bitwise or of one or more of    //!    //! VAR_EXPERT Only for experts