[51690] branches/gsoc09-gui/MacPorts_Framework
juanger at macports.org
juanger at macports.org
Sun May 31 11:13:38 PDT 2009
Revision: 51690
http://trac.macports.org/changeset/51690
Author: juanger at macports.org
Date: 2009-05-31 11:13:37 -0700 (Sun, 31 May 2009)
Log Message:
-----------
Changing ::ui_$priority proc to 1.8.0 version
Modified Paths:
--------------
branches/gsoc09-gui/MacPorts_Framework/init.tcl
branches/gsoc09-gui/MacPorts_Framework/interpInit.tcl
Modified: branches/gsoc09-gui/MacPorts_Framework/init.tcl
===================================================================
--- branches/gsoc09-gui/MacPorts_Framework/init.tcl 2009-05-31 18:08:48 UTC (rev 51689)
+++ branches/gsoc09-gui/MacPorts_Framework/init.tcl 2009-05-31 18:13:37 UTC (rev 51690)
@@ -126,21 +126,31 @@
#set prefix [ui_prefix $priority]
if {$nbchans == 1} {
- set chan [lindex $channels 0]
-
- proc ::ui_$priority {str} [subst {
- puts $chan "$prefix\$str"
- notifications send $nottype "$chan $prefix" "\$str"
- }]
+ set chan [lindex $channels 0]
+
+ proc ::ui_$priority {args} [subst {
+ if {\[lindex \$args 0\] == "-nonewline"} {
+ puts $chan "$prefix\[lindex \$args 1\]"
+ notifications send $nottype "$chan $prefix" "\[lindex \$args 1\]"
+ } else {
+ puts -nonewline $chan "$prefix\[lindex \$args 1\]"
+ notifications send $nottype "$chan $prefix" "\[lindex \$args 0\]"
+ }
+ }]
} else {
- proc ::ui_$priority {str} [subst {
- foreach chan \$channels {
- puts $chan "$prefix\$str"
- notifications send $nottype "$chan $prefix" "\$str"
- }
- }]
+ proc ::ui_$priority {args} [subst {
+ foreach chan \$channels {
+ if {\[lindex \$args 0\] == "-nonewline"} {
+ puts $chan "$prefix\[lindex \$args 1\]"
+ notifications send $nottype "$chan $prefix" "\[lindex \$args 1\]"
+ } else {
+ puts -nonewline $chan "$prefix\[lindex \$args 1\]"
+ notifications send $nottype "$chan $prefix" "\[lindex \$args 0\]"
+ }
+ }
+ }]
}
-
+
# Call ui_$priority - Is this step necessary? Consult with Randall
#::ui_$priority $message
}
@@ -150,7 +160,7 @@
#Wrapping the following API routines to catch errors
#and log error Information in a similar fashion to code
#in macports.tcl.
-proc mportuninstall {portname {v ""} optionslist} {
+proc mportuninstall {portname {v ""} {optionslist ""}} {
if {[catch {portuninstall::uninstall $portname $v $optionslist} result]} {
global errorInfo
@@ -180,6 +190,10 @@
}
}
+proc mportupgrade {args} \
+{
+
+}
# Initialize dport
Modified: branches/gsoc09-gui/MacPorts_Framework/interpInit.tcl
===================================================================
--- branches/gsoc09-gui/MacPorts_Framework/interpInit.tcl 2009-05-31 18:08:48 UTC (rev 51689)
+++ branches/gsoc09-gui/MacPorts_Framework/interpInit.tcl 2009-05-31 18:13:37 UTC (rev 51690)
@@ -128,20 +128,48 @@
#set prefix [ui_prefix $priority]
if {$nbchans == 1} {
- set chan [lindex $channels 0]
-
- proc ::ui_$priority {str} [subst {
- puts $chan "$prefix\$str"
- simplelog "$nottype $chan $prefix" "\$str"
- }]
+ set chan [lindex $channels 0]
+
+ proc ::ui_$priority {args} [subst {
+ if {\[lindex \$args 0\] == "-nonewline"} {
+ puts $chan "$prefix\[lindex \$args 1\]"
+ simplelog "$nottype $chan $prefix" "\[lindex \$args 1\]"
+ } else {
+ puts -nonewline $chan "$prefix\[lindex \$args 1\]"
+ simplelog "$nottype $chan $prefix" "\[lindex \$args 0\]"
+ }
+ }]
} else {
- proc ::ui_$priority {str} [subst {
- foreach chan \$channels {
- puts $chan "$prefix\$str"
- simplelog "$nottype $chan $prefix" "\$str"
- }
- }]
+ proc ::ui_$priority {args} [subst {
+ foreach chan \$channels {
+ if {\[lindex \$args 0\] == "-nonewline"} {
+ puts $chan "$prefix\[lindex \$args 1\]"
+ simplelog "$nottype $chan $prefix" "\[lindex \$args 1\]"
+ } else {
+ puts -nonewline $chan "$prefix\[lindex \$args 1\]"
+ simplelog "$nottype $chan $prefix" "\[lindex \$args 0\]"
+ }
+ }
+ }]
}
+
+
+
+ # if {$nbchans == 1} {
+ # set chan [lindex $channels 0]
+ #
+ # proc ::ui_$priority {str} [subst {
+ # puts $chan "$prefix\$str"
+ # simplelog "$nottype $chan $prefix" "\$str"
+ # }]
+ # } else {
+ # proc ::ui_$priority {str} [subst {
+ # foreach chan \$channels {
+ # puts $chan "$prefix\$str"
+ # simplelog "$nottype $chan $prefix" "\$str"
+ # }
+ # }]
+ # }
# Call ui_$priority - Is this step necessary? Consult with Randall
#::ui_$priority $message
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.macosforge.org/pipermail/macports-changes/attachments/20090531/0e0cac85/attachment.html>
More information about the macports-changes
mailing list