[DEVELOPMENT ENVIRONMENT]
* BUG: If a library or a component exports a form, then the special properties ('_IsForm' and '_HiddenControls') are not taken into account. git-svn-id: svn://localhost/gambas/trunk@5019 867c0c6c-44f3-4631-809d-bfa615b0a4ec
This commit is contained in:
parent
e46e481908
commit
143ce94b6a
2 changed files with 19 additions and 26 deletions
|
@ -286,7 +286,7 @@ msgstr ""
|
|||
msgid "OpenGL display"
|
||||
msgstr ""
|
||||
|
||||
#: CComponent.class:443
|
||||
#: CComponent.class:444
|
||||
msgid "Loading information on component &1..."
|
||||
msgstr ""
|
||||
|
||||
|
|
|
@ -425,6 +425,7 @@ Public Sub Load()
|
|||
Dim sLig As String
|
||||
Dim iPos As Integer
|
||||
Dim hClass As CClassInfo
|
||||
Dim hParent As CClassInfo
|
||||
Dim hSym As CSymbolInfo
|
||||
Dim hProp As CPropertyInfo
|
||||
Dim sParent As String
|
||||
|
@ -601,37 +602,29 @@ Public Sub Load()
|
|||
|
||||
hSym = hClass.Symbols["_IsForm"]
|
||||
If hSym And If hSym.Value Then
|
||||
If hClass.Parent Then
|
||||
hParent = Classes[hClass.ParentComponent &/ hClass.Parent]
|
||||
hSym = hParent.Symbols["_IsForm"]
|
||||
If hSym And If hSym.Value Then
|
||||
Hiddens.Add(sClass)
|
||||
Continue
|
||||
Endif
|
||||
Endif
|
||||
|
||||
hSym = hClass.Symbols["_HiddenControls"]
|
||||
If hSym Then Hiddens = Split(hSym.Value, ",")
|
||||
If hSym Then Hiddens.Insert(Split(hSym.Value, ","))
|
||||
|
||||
Endif
|
||||
|
||||
Next
|
||||
|
||||
' For Each sClass In Hiddens
|
||||
' If Classes.Exist(sClass) Then
|
||||
' Classes[Key &/ sClass].InitControl()
|
||||
' iPos = Controls.Find(sClass)
|
||||
' If iPos >= 0 Then Controls.Remove(iPos)
|
||||
' Endif
|
||||
' Next
|
||||
'
|
||||
' the upper code is the original code, I expanded
|
||||
'
|
||||
' this hack is because I can not load my projects into the IDE any more
|
||||
' seames to be a problem with requirement
|
||||
' the worst is, once loaded they work well
|
||||
' Charlie 03/08/2012 (after rev.5004)
|
||||
' _HiddenControls can be inherited, so its contents may be not significative
|
||||
|
||||
For Each sClass In Hiddens
|
||||
If Classes.Exist(sClass) Then
|
||||
' check if key exists in Classes
|
||||
If Classes.Exist(Key &/ sClass) Then
|
||||
Classes[Key &/ sClass].InitControl()
|
||||
iPos = Controls.Find(sClass)
|
||||
If iPos >= 0 Then Controls.Remove(iPos)
|
||||
Else
|
||||
' show it and continue
|
||||
FMain.ShowWarning("Classes[" & Key &/ sClass & "]\n\n Not Exists !")
|
||||
End If
|
||||
Endif
|
||||
Next
|
||||
|
||||
|
|
Loading…
Reference in a new issue