Garry's Mod Wiki

DTextEntry:OnLoseFocus

DTextEntry:OnLoseFocus()

Description

Called whenever the DTextEntry lose focus.

Example

local default = "Brick with bob" local textentry = vgui.Create( "DTextEntry" ) textentry:SetText( default ) textentry.OnLoseFocus = function( self ) if self:GetValue() == "" then self:SetValue( default ) end end
Output: DTextEntry value reset to default value if the text entered is empty.

Page Links


Special Pages


Wikis

?

Render Time: 23ms

DB GetPage 3
Generate Html 0
SaveChanges (1) 8
Render Body 0
Render Sidebar 9