From 169fb3fffeff55cff32952a82adba055dfc050f9 Mon Sep 17 00:00:00 2001 From: Bibiko Date: Wed, 10 Nov 2010 12:00:59 +0000 Subject: =?UTF-8?q?=E2=80=A2=20first=20implementation=20=20to=20allow=20th?= =?UTF-8?q?e=20user=20to=20write=20and=20use=20self-definable=20functions?= =?UTF-8?q?=20inside=20the=20Custom=20Query=20Editor=20-=20such=20commands?= =?UTF-8?q?=20will=20be=20stored=20as=20foo.spBundle=20in=20SP's=20Applica?= =?UTF-8?q?tion=20Folder/Bundles=20-=20up=20to=20now=20they=20will=20be=20?= =?UTF-8?q?displayed=20inside=20the=20context=20menu=20as=20submenu=20Bund?= =?UTF-8?q?les=20which=20can=20be=20by=20itself=20contain=20further=20subm?= =?UTF-8?q?enus=20specified=20via=20'category'=20key=20-=20to=20each=20com?= =?UTF-8?q?mand=20the=20user=20can=20assign=20a=20tooltip=20and=20a=20keyb?= =?UTF-8?q?oard=20short-cut;=20if=20user=20chose=20a=20standard=20SP=20sho?= =?UTF-8?q?rt-cut=20it=20will=20be=20ignored=20-=20commands=20will=20be=20?= =?UTF-8?q?executed=20as=20bash=20commands=20ie=20it=20can=20also=20be=20w?= =?UTF-8?q?ritten=20in=20any=20script=20language=20-=20the=20bash=20proces?= =?UTF-8?q?s=20inherits=20several=20environment=20variables=20like=20SP=5F?= =?UTF-8?q?BUNDLE=5FPATH,=20SP=5FSELECTED=5FTEXT,=20SP=5FSELECTED=5FDATABA?= =?UTF-8?q?SE,=20SP=5FSELECTED=5FTABLE,=20SP=5FCURRENT=5FQUERY,=20SP=5FCUR?= =?UTF-8?q?RENT=5FLINE,=20SP=5FCURRENT=5FWORD=20-=20the=20bash=20command's?= =?UTF-8?q?=20result=20can=20be=20processed=20as=20follows:=20insertAsText?= =?UTF-8?q?,=20insertAsSnippet,=20replaceContent,=20replaceSeletion=20(wit?= =?UTF-8?q?h=20fallbacks=20to=20word,=20line,=20query,=20entire=20content)?= =?UTF-8?q?,=20showAsTextTooltip,=20showAsHTMLTooltip=20-=20up=20to=20now?= =?UTF-8?q?=20all=20installed=20bundles=20are=20reload=20for=20each=20menu?= =?UTF-8?q?ForEvent:=20[this=20is=20tendative!]=20-=20each=20spBundle=20co?= =?UTF-8?q?mmand=20has=20a=20scope=20to=20allow=20to=20the=20user=20to=20s?= =?UTF-8?q?pecify=20for=20which=20SP=20element=20a=20command=20can=20be=20?= =?UTF-8?q?useful;=20up=20to=20now=20only=20the=20scope=20'editor'=20is=20?= =?UTF-8?q?supported;=20further=20scopes=20could=20be=20'data=20table'=20f?= =?UTF-8?q?or=20context=20menus=20of=20mysql=20table=20data=20(Content=20o?= =?UTF-8?q?r=20Custom=20Query=20-=20including=20info=20of=20selected=20lin?= =?UTF-8?q?es,=20table=20data=20in=20different=20formats,=20etc.)?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit - foo.spBundle files can be installed simply by double-clicking at it (remember up to now Bundles will be reloaded while opening the editor's context menu!) two tiny examples for testing: http://wwwstaff.eva.mpg.de/~bibiko/dt/temp/spBundleExamples.zip --- Source/SPDatabaseDocument.m | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) (limited to 'Source/SPDatabaseDocument.m') diff --git a/Source/SPDatabaseDocument.m b/Source/SPDatabaseDocument.m index 75a16e73..f3f419d8 100644 --- a/Source/SPDatabaseDocument.m +++ b/Source/SPDatabaseDocument.m @@ -241,7 +241,9 @@ [taskProgressWindow setAlphaValue:0.0]; [taskProgressWindow setContentView:taskProgressLayer]; - [contentViewSplitter setDelegate:self]; + [[customQueryInstance valueForKeyPath:@"textView"] reloadBundleItems]; + + [contentViewSplitter setDelegate:self]; } /** -- cgit v1.2.3