[Kde-bindings] branches/work/kdebindings-smoke2
Arno Rehn
kde at arnorehn.de
Sun Feb 10 17:25:50 UTC 2008
SVN commit 773261 by arnorehn:
* Bring back the namespaces. gmcs won't crash with namespaces instead of
partial classes and it improves the style of the code.
* Added dom, kparts and kio modules.
* Moved sonnet from kde/ to sonnet/ directory.
CCMAIL: kde-bindings at kde.org
M +7 -0 ChangeLog
M +9 -1 csharp/kimono/CMakeLists.txt
A csharp/kimono/dom (directory)
A csharp/kimono/dom/DOM_AbstractView.cs
A csharp/kimono/dom/DOM_Attr.cs
A csharp/kimono/dom/DOM_CDATASection.cs
A csharp/kimono/dom/DOM_CSSCharsetRule.cs
A csharp/kimono/dom/DOM_CSSException.cs
A csharp/kimono/dom/DOM_CSSFontFaceRule.cs
A csharp/kimono/dom/DOM_CSSImportRule.cs
A csharp/kimono/dom/DOM_CSSMediaRule.cs
A csharp/kimono/dom/DOM_CSSPageRule.cs
A csharp/kimono/dom/DOM_CSSPrimitiveValue.cs
A csharp/kimono/dom/DOM_CSSRule.cs
A csharp/kimono/dom/DOM_CSSRuleList.cs
A csharp/kimono/dom/DOM_CSSStyleDeclaration.cs
A csharp/kimono/dom/DOM_CSSStyleRule.cs
A csharp/kimono/dom/DOM_CSSStyleSheet.cs
A csharp/kimono/dom/DOM_CSSUnknownRule.cs
A csharp/kimono/dom/DOM_CSSValue.cs
A csharp/kimono/dom/DOM_CSSValueList.cs
A csharp/kimono/dom/DOM_CharacterData.cs
A csharp/kimono/dom/DOM_Comment.cs
A csharp/kimono/dom/DOM_Counter.cs
A csharp/kimono/dom/DOM_CustomNodeFilter.cs
A csharp/kimono/dom/DOM_DOMException.cs
A csharp/kimono/dom/DOM_DOMImplementation.cs
A csharp/kimono/dom/DOM_DOMString.cs
A csharp/kimono/dom/DOM_Document.cs
A csharp/kimono/dom/DOM_DocumentFragment.cs
A csharp/kimono/dom/DOM_DocumentStyle.cs
A csharp/kimono/dom/DOM_DocumentType.cs
A csharp/kimono/dom/DOM_DomShared.cs
A csharp/kimono/dom/DOM_Element.cs
A csharp/kimono/dom/DOM_Entity.cs
A csharp/kimono/dom/DOM_EntityReference.cs
A csharp/kimono/dom/DOM_Event.cs
A csharp/kimono/dom/DOM_EventException.cs
A csharp/kimono/dom/DOM_EventListener.cs
A csharp/kimono/dom/DOM_HTMLAnchorElement.cs
A csharp/kimono/dom/DOM_HTMLAppletElement.cs
A csharp/kimono/dom/DOM_HTMLAreaElement.cs
A csharp/kimono/dom/DOM_HTMLBRElement.cs
A csharp/kimono/dom/DOM_HTMLBaseElement.cs
A csharp/kimono/dom/DOM_HTMLBaseFontElement.cs
A csharp/kimono/dom/DOM_HTMLBlockquoteElement.cs
A csharp/kimono/dom/DOM_HTMLBodyElement.cs
A csharp/kimono/dom/DOM_HTMLButtonElement.cs
A csharp/kimono/dom/DOM_HTMLCollection.cs
A csharp/kimono/dom/DOM_HTMLDListElement.cs
A csharp/kimono/dom/DOM_HTMLDirectoryElement.cs
A csharp/kimono/dom/DOM_HTMLDivElement.cs
A csharp/kimono/dom/DOM_HTMLDocument.cs
A csharp/kimono/dom/DOM_HTMLElement.cs
A csharp/kimono/dom/DOM_HTMLFieldSetElement.cs
A csharp/kimono/dom/DOM_HTMLFontElement.cs
A csharp/kimono/dom/DOM_HTMLFormCollection.cs
A csharp/kimono/dom/DOM_HTMLFormElement.cs
A csharp/kimono/dom/DOM_HTMLFrameElement.cs
A csharp/kimono/dom/DOM_HTMLFrameSetElement.cs
A csharp/kimono/dom/DOM_HTMLHRElement.cs
A csharp/kimono/dom/DOM_HTMLHeadElement.cs
A csharp/kimono/dom/DOM_HTMLHeadingElement.cs
A csharp/kimono/dom/DOM_HTMLHtmlElement.cs
A csharp/kimono/dom/DOM_HTMLIFrameElement.cs
A csharp/kimono/dom/DOM_HTMLImageElement.cs
A csharp/kimono/dom/DOM_HTMLInputElement.cs
A csharp/kimono/dom/DOM_HTMLIsIndexElement.cs
A csharp/kimono/dom/DOM_HTMLLIElement.cs
A csharp/kimono/dom/DOM_HTMLLabelElement.cs
A csharp/kimono/dom/DOM_HTMLLayerElement.cs
A csharp/kimono/dom/DOM_HTMLLegendElement.cs
A csharp/kimono/dom/DOM_HTMLLinkElement.cs
A csharp/kimono/dom/DOM_HTMLMapElement.cs
A csharp/kimono/dom/DOM_HTMLMenuElement.cs
A csharp/kimono/dom/DOM_HTMLMetaElement.cs
A csharp/kimono/dom/DOM_HTMLModElement.cs
A csharp/kimono/dom/DOM_HTMLOListElement.cs
A csharp/kimono/dom/DOM_HTMLObjectElement.cs
A csharp/kimono/dom/DOM_HTMLOptGroupElement.cs
A csharp/kimono/dom/DOM_HTMLOptionElement.cs
A csharp/kimono/dom/DOM_HTMLParagraphElement.cs
A csharp/kimono/dom/DOM_HTMLParamElement.cs
A csharp/kimono/dom/DOM_HTMLPreElement.cs
A csharp/kimono/dom/DOM_HTMLQuoteElement.cs
A csharp/kimono/dom/DOM_HTMLScriptElement.cs
A csharp/kimono/dom/DOM_HTMLSelectElement.cs
A csharp/kimono/dom/DOM_HTMLStyleElement.cs
A csharp/kimono/dom/DOM_HTMLTableCaptionElement.cs
A csharp/kimono/dom/DOM_HTMLTableCellElement.cs
A csharp/kimono/dom/DOM_HTMLTableColElement.cs
A csharp/kimono/dom/DOM_HTMLTableElement.cs
A csharp/kimono/dom/DOM_HTMLTableRowElement.cs
A csharp/kimono/dom/DOM_HTMLTableSectionElement.cs
A csharp/kimono/dom/DOM_HTMLTextAreaElement.cs
A csharp/kimono/dom/DOM_HTMLTitleElement.cs
A csharp/kimono/dom/DOM_HTMLUListElement.cs
A csharp/kimono/dom/DOM_KeyboardEvent.cs
A csharp/kimono/dom/DOM_LinkStyle.cs
A csharp/kimono/dom/DOM_MediaList.cs
A csharp/kimono/dom/DOM_MouseEvent.cs
A csharp/kimono/dom/DOM_MutationEvent.cs
A csharp/kimono/dom/DOM_NamedNodeMap.cs
A csharp/kimono/dom/DOM_Node.cs
A csharp/kimono/dom/DOM_NodeFilter.cs
A csharp/kimono/dom/DOM_NodeIterator.cs
A csharp/kimono/dom/DOM_NodeList.cs
A csharp/kimono/dom/DOM_Notation.cs
A csharp/kimono/dom/DOM_ProcessingInstruction.cs
A csharp/kimono/dom/DOM_RGBColor.cs
A csharp/kimono/dom/DOM_Range.cs
A csharp/kimono/dom/DOM_RangeException.cs
A csharp/kimono/dom/DOM_Rect.cs
A csharp/kimono/dom/DOM_StyleSheet.cs
A csharp/kimono/dom/DOM_StyleSheetList.cs
A csharp/kimono/dom/DOM_Text.cs
A csharp/kimono/dom/DOM_TextEvent.cs
A csharp/kimono/dom/DOM_TreeWalker.cs
A csharp/kimono/dom/DOM_UIEvent.cs
A csharp/kimono/kde/KFileItem.cs
A csharp/kimono/kde/KHTMLPart.cs
A csharp/kimono/kde/KHTMLSettings.cs
A csharp/kimono/kde/KHTMLView.cs
A csharp/kimono/kde/KRun.cs
D csharp/kimono/kde/KWallet.cs
M +1 -1 csharp/kimono/kde/KWallet_Wallet.cs
D csharp/kimono/kde/Sonnet.cs
D csharp/kimono/kde/Sonnet_BackgroundChecker.cs
D csharp/kimono/kde/Sonnet_ConfigDialog.cs
D csharp/kimono/kde/Sonnet_ConfigWidget.cs
D csharp/kimono/kde/Sonnet_Dialog.cs
D csharp/kimono/kde/Sonnet_Highlighter.cs
D csharp/kimono/kde/Sonnet_Speller.cs
A csharp/kimono/kio (directory)
A csharp/kimono/kio/KIO.cs
A csharp/kimono/kio/KIO_AuthInfo.cs
A csharp/kimono/kio/KIO_Connection.cs
A csharp/kimono/kio/KIO_ConnectionServer.cs
A csharp/kimono/kio/KIO_CopyInfo.cs
A csharp/kimono/kio/KIO_CopyJob.cs
A csharp/kimono/kio/KIO_DavJob.cs
A csharp/kimono/kio/KIO_DeleteJob.cs
A csharp/kimono/kio/KIO_DirectorySizeJob.cs
A csharp/kimono/kio/KIO_FileCopyJob.cs
A csharp/kimono/kio/KIO_FileJob.cs
A csharp/kimono/kio/KIO_ForwardingSlaveBase.cs
A csharp/kimono/kio/KIO_Job.cs
A csharp/kimono/kio/KIO_JobUiDelegate.cs
A csharp/kimono/kio/KIO_ListJob.cs
A csharp/kimono/kio/KIO_MetaData.cs
A csharp/kimono/kio/KIO_MetaInfoJob.cs
A csharp/kimono/kio/KIO_MimetypeJob.cs
A csharp/kimono/kio/KIO_MultiGetJob.cs
A csharp/kimono/kio/KIO_NetAccess.cs
A csharp/kimono/kio/KIO_PreviewJob.cs
A csharp/kimono/kio/KIO_RenameDialog.cs
A csharp/kimono/kio/KIO_Scheduler.cs
A csharp/kimono/kio/KIO_SessionData.cs
A csharp/kimono/kio/KIO_SimpleJob.cs
A csharp/kimono/kio/KIO_SkipDialog.cs
A csharp/kimono/kio/KIO_Slave.cs
A csharp/kimono/kio/KIO_SlaveBase.cs
A csharp/kimono/kio/KIO_SlaveConfig.cs
A csharp/kimono/kio/KIO_SlaveInterface.cs
A csharp/kimono/kio/KIO_SpecialJob.cs
A csharp/kimono/kio/KIO_StatJob.cs
A csharp/kimono/kio/KIO_StoredTransferJob.cs
A csharp/kimono/kio/KIO_TCPSlaveBase.cs
A csharp/kimono/kio/KIO_TransferJob.cs
A csharp/kimono/kio/KIO_UDSEntry.cs
A csharp/kimono/kparts (directory)
A csharp/kimono/kparts/KParts.cs
A csharp/kimono/kparts/KParts_BrowserArguments.cs
A csharp/kimono/kparts/KParts_BrowserExtension.cs
A csharp/kimono/kparts/KParts_BrowserHostExtension.cs
A csharp/kimono/kparts/KParts_BrowserInterface.cs
A csharp/kimono/kparts/KParts_BrowserRun.cs
A csharp/kimono/kparts/KParts_Event.cs
A csharp/kimono/kparts/KParts_Factory.cs
A csharp/kimono/kparts/KParts_GUIActivateEvent.cs
A csharp/kimono/kparts/KParts_HistoryProvider.cs
A csharp/kimono/kparts/KParts_LiveConnectExtension.cs
A csharp/kimono/kparts/KParts_OpenUrlArguments.cs
A csharp/kimono/kparts/KParts_OpenUrlEvent.cs
A csharp/kimono/kparts/KParts_Part.cs
A csharp/kimono/kparts/KParts_PartActivateEvent.cs
A csharp/kimono/kparts/KParts_PartBase.cs
A csharp/kimono/kparts/KParts_PartManager.cs
A csharp/kimono/kparts/KParts_PartSelectEvent.cs
A csharp/kimono/kparts/KParts_Plugin.cs
A csharp/kimono/kparts/KParts_ReadOnlyPart.cs
A csharp/kimono/kparts/KParts_ReadWritePart.cs
A csharp/kimono/kparts/KParts_StatusBarExtension.cs
A csharp/kimono/kparts/KParts_WindowArgs.cs
A csharp/kimono/sonnet (directory)
A csharp/kimono/sonnet/Sonnet_BackgroundChecker.cs
A csharp/kimono/sonnet/Sonnet_ConfigDialog.cs
A csharp/kimono/sonnet/Sonnet_ConfigWidget.cs
A csharp/kimono/sonnet/Sonnet_Dialog.cs
A csharp/kimono/sonnet/Sonnet_Highlighter.cs
A csharp/kimono/sonnet/Sonnet_Speller.cs
M +28 -9 kalyptus/kalyptusCxxToKimono.pm
--- branches/work/kdebindings-smoke2/ChangeLog #773260:773261
@@ -1,3 +1,10 @@
+2008-02-10 Arno Rehn <arno at arnorehn.de>
+
+ * Bring back the namespaces. gmcs won't crash with namespaces instead of
+ partial classes and it improves the style of the code.
+ * Added dom, kparts and kio modules.
+ * Moved sonnet from kde/ to sonnet/ directory.
+
2008-02-09 Arno Rehn <arno at arnorehn.de>
* Regenerated KDE classes from the 4.0 headers
--- branches/work/kdebindings-smoke2/csharp/kimono/CMakeLists.txt #773260:773261
@@ -3,8 +3,16 @@
INCLUDE (CSharpMacros)
SET(SRC_CPP src/kimono.cpp)
-SET(SRC_CS kde/*.cs src/SmokeInvocationKDE.cs src/AssemblyInfo.cs)
+SET(SRC_CS
+kde/*.cs
+kio/*.cs
+sonnet/*.cs
+dom/*.cs
+kparts/*.cs
+src/SmokeInvocationKDE.cs
+src/AssemblyInfo.cs)
+
INCLUDE_DIRECTORIES (${QT_INCLUDES} ${KDE4_INCLUDE_DIR} ${CMAKE_SOURCE_DIR}/smoke ${CMAKE_CURRENT_SOURCE_DIR}/../qyoto/src ${CMAKE_CURRENT_SOURCE_DIR}/src)
ADD_LIBRARY(kimono MODULE ${SRC_CPP})
--- branches/work/kdebindings-smoke2/csharp/kimono/kde/KWallet_Wallet.cs #773260:773261
@@ -5,8 +5,8 @@
using Qyoto;
using System.Text;
using System.Collections.Generic;
- public partial class KWallet {
+ namespace KWallet {
/// <remarks>
/// KDE Wallet
--- branches/work/kdebindings-smoke2/kalyptus/kalyptusCxxToKimono.pm #773260:773261
@@ -528,11 +528,12 @@
if ($className =~ /^(\w+)::(\w+)$/) {
$node = kdocAstUtil::findRef( $rootnode, $1 );
$item = kdocAstUtil::findRef( $node, $2 ) if defined $node;
+ my $first = ($node->{NodeType} eq 'namespace' and $1 ne 'Qt') ? "$1" . "Namespace" : "$1"; # only relevant for enums
if (defined $item && $item->{NodeType} eq 'enum') {
if ($2 eq 'Type') {
- return "$1.TypeOf";
+ return "$first.TypeOf";
} else {
- return "$1.$2";
+ return "$first.$2";
}
} elsif (defined $item && ($item->{NodeType} eq 'class' || $item->{NodeType} eq 'struct')) {
@@ -1159,7 +1160,11 @@
# $classdec .= "\tnamespace $className {\n";
# if ( $partial_classes{$csharpClassName} ) {
+ if ($csharpClassName ne 'Qt') {
+ $classdec .= "\tpublic partial class $csharpClassName" . "Namespace : Object {\n";
+ } else {
$classdec .= "\tpublic partial class $csharpClassName : Object {\n";
+ }
# } else {
# $classdec .= "\tpublic class $csharpClassName : Object {\n";
# }
@@ -1299,9 +1304,11 @@
}
if ($proxyInterfaceCode ne '') {
+ my $tempClassName = ($node->{NodeType} eq 'namespace' and $csharpClassName ne 'Qt') ? $csharpClassName . "Namespace" : $csharpClassName;
$classCode .= "$indent\t\tprivate static $main::smokeInvocation staticInterceptor = null;\n";
- $classCode .= "$indent\t\tstatic $csharpClassName() {\n";
- $classCode .= "$indent\t\t\tstaticInterceptor = new $main::smokeInvocation(typeof($csharpClassName), null);\n";
+
+ $classCode .= "$indent\t\tstatic $tempClassName() {\n";
+ $classCode .= "$indent\t\t\tstaticInterceptor = new $main::smokeInvocation(typeof($tempClassName), null);\n";
$classCode .= "$indent\t\t}\n";
}
@@ -1366,8 +1373,16 @@
}
my $namespace;
- if ($className =~ /([^:]*)::.*/) {
- $namespace = $1;
+ my $partialClass;
+# if ($className =~ /([^:]*)::.*/) {
+# $namespace = $1;
+# }
+ if ($node->{NodeType} eq 'namespace') {
+ $namespace = $node->{astNodeName};
+ } elsif ($node->{Parent}->{NodeType} eq 'namespace') {
+ $namespace = $node->{Parent}->{astNodeName};
+ } elsif ($className =~ /([^:]*)::.*/) {
+ $partialClass = $1;
}
my %addImport = ();
@@ -1393,13 +1408,17 @@
}
}
- if (defined $namespace) {
- print CLASS "\tpublic partial class $namespace {\n\n";
+ if ($className ne 'Qt') {
+ if (defined $namespace) {
+ print CLASS "\n\tnamespace $namespace {\n";
+ } elsif (defined $partialClass) {
+ print CLASS "\n\tpublic partial class $partialClass {\n";
+ }
}
print CLASS $classCode;
- if (defined $namespace) {
+ if ((defined $namespace or defined $partialClass) and $className ne 'Qt') {
print CLASS "\t}\n";
}
More information about the Kde-bindings
mailing list