of_getsystemsettings


pfcwnsrv.pbl   >   pfc_w_statusbar   >   of_getsystemsettings   

Full name pfc_w_statusbar.of_getsystemsettings
Access protected
Override of integer
Return value integer
Prototype protected function integer of_getsystemsettings()

Name Datatype
No Data

Name Datatype
li_border integer
lnv_platform n_cst_platform
ls_buttonface string
ls_temp string

protected function integer of_getsystemsettings ();//////////////////////////////////////////////////////////////////////////////
//
//	Function:  of_GetSystemSettings
//
//	Access:  protected
//
//	Arguments : None
//
//	Returns:  Integer
//	1 if it succeeds and -1 if an error occurs.
//
//	Description:  
//	Get the needed settings from the registry or win.ini
//
//////////////////////////////////////////////////////////////////////////////
//
//	Revision History
//
//	Version
//	5.0   Initial version
// 5.0.02 Provide default value for buttonface Color.
// 5.0.03 Added WindowNT 4.0 support.
// 7.0	 Changed calculation of border size
//
//////////////////////////////////////////////////////////////////////////////
//
//	Copyright © 1996-1997 Sybase, Inc. and its subsidiaries.  All rights reserved.
//	Any distribution of the PowerBuilder Foundation Classes (PFC)
//	source code by other than Sybase, Inc. and its subsidiaries is prohibited.
//
//////////////////////////////////////////////////////////////////////////////

string ls_temp
string ls_buttonface
integer li_border
n_cst_platform lnv_platform

f_setplatform(lnv_platform, true)

li_border = lnv_platform.of_GetActiveWindowBorder()
RegistryGet ('hkey_current_user\control panel\colors', 'buttonface', ls_buttonface)

IF li_border > 0 THEN
	ii_borderheight = PixelsToUnits(li_border, ypixelstounits!)
	ii_borderwidth = PixelsToUnits(li_border, xpixelstounits!)
END IF

// Provide default value for the ButtonFace color.
If IsNull(ls_buttonface) or Len(ls_buttonface)=0 Then
	il_buttonface = 78682240
Else
	il_buttonface = of_Color(ls_buttonface)
End If

f_setplatform(lnv_platform, false)

Return 1
end function

     
Name Owner
pfc_w_statusbar.wininichange pfc_w_statusbar
pfc_w_statusbar.open pfc_w_statusbar

     
Name Owner
systemfunctions.isnull systemfunctions
systemfunctions.len systemfunctions
systemfunctions.pixelstounits systemfunctions
systemfunctions.registryget systemfunctions
pfc_n_cst_platform.of_getactivewindowborder pfc_n_cst_platform
f_setplatform.f_setplatform f_setplatform
pfc_w_statusbar.of_color pfc_w_statusbar

     
Full name
No Data

     
Name Scope
No Data