Skip to content

Commit c643dfe

Browse files
committed
Fixed crash at init project if array of lang was not filled. (3)
1 parent c5c2f98 commit c643dfe

File tree

2 files changed

+66
-58
lines changed

2 files changed

+66
-58
lines changed

src/ideU.prj

Lines changed: 58 additions & 57 deletions
Original file line numberDiff line numberDiff line change
@@ -936,7 +936,7 @@ makeoptionson=16
936936
4095
937937
4095
938938
1
939-
1226
939+
1230
940940
2046
941941
4095
942942
192
@@ -1302,33 +1302,33 @@ line=27
13021302
8
13031303
2604
13041304
address=27
1305-
4882385
1305+
4882535
13061306
4704597
13071307
4854269
1308-
4907503
1309-
8234634
1310-
8515793
1311-
8950726
1312-
8138461
1313-
8136296
1314-
8144137
1315-
8161628
1308+
4907667
1309+
8235018
1310+
8516177
1311+
8951110
1312+
8138476
1313+
8136598
1314+
8144218
1315+
8161835
13161316
5887456
13171317
4853389
13181318
4692233
13191319
4422044
13201320
0
13211321
4736457
13221322
0
1323-
8943650
1323+
8944034
13241324
4718330
1325-
8145274
1326-
4957868
1327-
4995993
1328-
6686216
1329-
8594301
1330-
10540221
1331-
4895689
1325+
8145404
1326+
4957910
1327+
4996201
1328+
6686424
1329+
8594685
1330+
10540605
1331+
4895837
13321332
addbkpt=27
13331333
0
13341334
0
@@ -1584,24 +1584,24 @@ findhistory=20
15841584
info :=
15851585
findoptions=1
15861586
editpos=4
1587-
22,992
15881587
0,0
15891588
0,-1073741823
1590-
0,18
1589+
0,0
1590+
0,-1073741823
15911591
bookmarks0=0
15921592
bookmarks1=0
15931593
bookmarks2=0
15941594
bookmarks3=0
15951595
sourcefiles=4
1596-
${PROJECTDIR}/main.pas
1596+
${PROJECTDIR}/ideU.pas
15971597
${PROJECTDIR}/sourceform.pas
15981598
${PROJECTDIR}/actionsmodule.pas
1599-
${PROJECTDIR}/captionideu.pas
1599+
${PROJECTDIR}/main.pas
16001600
relpaths=4
1601-
main.pas
1601+
ideU.pas
16021602
sourceform.pas
16031603
actionsmodule.pas
1604-
captionideu.pas
1604+
main.pas
16051605
ismoduletexts=4
16061606
0
16071607
0
@@ -1626,13 +1626,13 @@ nomenumodules=3
16261626
[sourcefo.files_tab]
16271627
order=4
16281628
0
1629+
2
16291630
3
16301631
1
1631-
2
16321632
firsttab=0
1633-
index=0
1633+
index=1
16341634
[layout]
1635-
windowlayout=531
1635+
windowlayout=532
16361636
[mainfo.basedock]
16371637
splitdir=2
16381638
useroptions=268450944
@@ -1646,13 +1646,13 @@ windowlayout=531
16461646
ny=0
16471647
ncx=0
16481648
ncy=0
1649-
x=109
1650-
y=70
1649+
x=79
1650+
y=109
16511651
cx=1224
16521652
cy=621
16531653
rcx=0
16541654
rcy=0
1655-
wsize=6
1655+
wsize=0
16561656
active=1
16571657
visible=1
16581658
[findmessagefo.findtext]
@@ -1692,15 +1692,15 @@ windowlayout=531
16921692
ny=0
16931693
ncx=0
16941694
ncy=0
1695-
x=421
1696-
y=562
1697-
cx=760
1695+
x=444
1696+
y=431
1697+
cx=418
16981698
cy=126
16991699
rcx=0
17001700
rcy=0
17011701
wsize=0
17021702
active=0
1703-
visible=1
1703+
visible=0
17041704
[memoryfo]
17051705
splitdir=0
17061706
useroptions=268451963
@@ -1750,7 +1750,7 @@ windowlayout=531
17501750
[findinfilefo]
17511751
splitdir=0
17521752
useroptions=268451947
1753-
stackedunder=targetconsolefo
1753+
stackedunder=
17541754
parent=
17551755
mdistate=0
17561756
nx=0
@@ -1759,7 +1759,7 @@ windowlayout=531
17591759
ncy=0
17601760
x=239
17611761
y=115
1762-
cx=832
1762+
cx=678
17631763
cy=414
17641764
rcx=0
17651765
rcy=0
@@ -1776,7 +1776,7 @@ windowlayout=531
17761776
x=0
17771777
y=0
17781778
cx=205
1779-
cy=522
1779+
cy=448
17801780
rcx=0
17811781
rcy=0
17821782
[projecttreefo.grid]
@@ -1800,13 +1800,13 @@ windowlayout=531
18001800
ncy=0
18011801
x=423
18021802
y=321
1803-
cx=764
1804-
cy=297
1803+
cx=344
1804+
cy=155
18051805
rcx=0
18061806
rcy=0
18071807
wsize=0
18081808
active=0
1809-
visible=1
1809+
visible=0
18101810
[watchpointsfo]
18111811
splitdir=0
18121812
useroptions=268451945
@@ -1944,9 +1944,9 @@ windowlayout=531
19441944
ncx=0
19451945
ncy=0
19461946
x=0
1947-
y=583
1948-
cx=1354
1949-
cy=107
1947+
y=508
1948+
cx=1212
1949+
cy=92
19501950
rcx=0
19511951
rcy=0
19521952
[componentstorefo]
@@ -2045,8 +2045,8 @@ windowlayout=531
20452045
ncy=0
20462046
x=0
20472047
y=0
2048-
cx=1354
2049-
cy=55
2048+
cx=1212
2049+
cy=54
20502050
rcx=0
20512051
rcy=0
20522052
[debuggerfo.basedock]
@@ -2061,8 +2061,8 @@ windowlayout=531
20612061
ncy=61
20622062
x=0
20632063
y=0
2064-
cx=1354
2065-
cy=62
2064+
cx=1212
2065+
cy=61
20662066
rcx=0
20672067
rcy=0
20682068
[debuggerfo.edit_options]
@@ -2072,10 +2072,11 @@ windowlayout=531
20722072
[debuggerfo.edit_compiler]
20732073
value=Pascal
20742074
[debuggerfo.file_history]
2075-
value=/home/fred/ideU/src/main.pas
2076-
history=5
2075+
value=/home/fred/ideU/src/objectinspector.pas
2076+
history=6
2077+
/home/fred/ideU/src/main.pas
2078+
/home/fred/ideU/src/ideU.pas
20772079
/home/fred/ideU/src/actionsmodule.pas
2078-
/home/fred/mseide-msegui/apps/ide/actionsmodule.mfm
20792080

20802081
/home/fred/ideU/src/layout
20812082
${PROJECTDIR}/main.pas
@@ -2095,18 +2096,18 @@ windowlayout=531
20952096
ncy=0
20962097
x=208
20972098
y=0
2098-
cx=1146
2099-
cy=522
2099+
cx=1004
2100+
cy=448
21002101
rcx=0
21012102
rcy=0
21022103
[sourcefo.files_tab]
21032104
order=4
21042105
0
2106+
2
21052107
3
21062108
1
2107-
2
21082109
firsttab=0
2109-
index=0
2110+
index=1
21102111
[confideufo.usedefaulteditoroptions]
21112112
value=0
21122113
[cpuc86_64fo]
@@ -2140,9 +2141,9 @@ windowlayout=531
21402141
ncx=0
21412142
ncy=0
21422143
x=0
2143-
y=58
2144-
cx=1354
2145-
cy=522
2144+
y=57
2145+
cx=1212
2146+
cy=448
21462147
rcx=0
21472148
rcy=0
21482149
[_mse_mainfo_mse_]

src/objectinspector.pas

Lines changed: 8 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -706,16 +706,23 @@ procedure tobjectinspectorfo.moduleactivated(const adesigner: idesigner;
706706
const amodule: tmsecomponent);
707707
begin
708708
factmodule:= amodule;
709+
if length(lang_actionsmodule) > ord(ac_objectinspector) then
709710
caption:= lang_actionsmodule[ord(ac_objectinspector)] + ' (' +
711+
msestring(amodule.Name)+')'
712+
else
713+
caption:= 'Object Inspector (' +
710714
msestring(amodule.Name)+')';
715+
711716
updatecomponentname;
712717
// clear;
713718
end;
714719

715720
procedure tobjectinspectorfo.moduledeactivated(const adesigner: idesigner;
716721
const amodule: tmsecomponent);
717722
begin
718-
caption:= lang_actionsmodule[ord(ac_objectinspector)];
723+
if length(lang_actionsmodule) > ord(ac_objectinspector) then
724+
caption:= lang_actionsmodule[ord(ac_objectinspector)] else
725+
caption:= 'Object Inspector';
719726
// clear;
720727
factmodule:= nil;
721728
end;

0 commit comments

Comments
 (0)