# inputEx-library

### inputEx 0.5.1

inputEx-library > inputEx > inputEx.InPlaceEdit
Search:
Filters Show Private Show Protected Show Deprecated

## Class inputEx.InPlaceEdit - extends inputEx.Field

Meta field providing in place editing (the editor appears when you click on the formatted value).

### Constructor

inputEx.InPlaceEdit `( options )`

Parameters:
  `options <Object>` Added options:
  - visu
  - editorField
  - animColors

#### Properties inherited from inputEx.Field:

`options`

### Methods

#### close

`void close ( )`
Close the editor when calling the close function on this field

#### getValue

`Any getValue ( )`
Returned the previously stored value

Returns: `Any`
  The value of the subfield

#### initEvents

`void initEvents ( )`
Adds the events for the editor and color animations

#### onCancelEditor

`void onCancelEditor ( e )`
Close the editor on cancel (cancel button, blur event or escape key)

Parameters:
  `e <Event>` The original event (click, blur or keydown)

#### onKeyDown

`void onKeyDown ( e )`
Handle the tabulation key to close the editor

Parameters:
  `e <Event>` The original keydown event

#### onKeyUp

`void onKeyUp ( e )`
Handle some keys events to close the editor

Parameters:
  `e <Event>` The original keyup event

#### onOkEditor

`void onOkEditor ( )`
Validate the editor (ok button, enter key or tabulation key)

#### onVisuMouseOut

`void onVisuMouseOut ( e )`
Start the color animation when hovering the field

Parameters:
  `e <Event>` The original mouseout event

#### onVisuMouseOver

`void onVisuMouseOver ( e )`
Set the color when hovering the field

Parameters:
  `e <Event>` The original mouseover event

#### openEditor

`void openEditor ( )`
Display the editor

#### renderComponent

`void renderComponent ( )`
Override renderComponent to create 2 divs: the visualization one, and the edit in place form

#### renderEditor

`void renderEditor ( )`
Render the editor

#### renderVisuDiv

`void renderVisuDiv ( )`
Create the div that will contain the visualization of the value

#### setOptions

`void setOptions ( options )`
Set the default values of the options

Parameters:
  `options <Object>` Options object as passed to the constructor

#### setValue

`void setValue ( value , [sendUpdatedEvt] )`
Set the value and update the display

Parameters:
  `value <Any>` The value to set
  `[sendUpdatedEvt] <boolean>` (optional) Wether this setValue should fire the updatedEvt or not (default is true, pass false to NOT send the event)

#### Methods inherited from inputEx.Field:

`clear, close, destroy, disable, displayMessage, enable, fireUpdatedEvt, focus, getEl, getParentField, getState, getStateString, getValue, hide, initEvents, isDisabled, isEmpty, onBlur, onChange, onFocus, render, renderComponent, setClassFromState, setFieldName, setOptions, setParentField, setValue, show, validate`

#### Events inherited from inputEx.Field:

`updatedEvt,`

Copyright © 2010 Eric Abouaf All rights reserved.