[squeak-dev] The Inbox: Tools-laza.218.mcz

Chris Muller asqueaker at gmail.com
Mon Mar 22 18:55:25 UTC 2010


Can this be a preference please?

I prefer the instVars to be displayed in slot-order..  If we have so
many instVars in the list that alphabetization helps then I would use
the keyboard anyway; manual eye-scanning is for the birds!



On Mon, Mar 22, 2010 at 11:16 AM,  <commits at source.squeak.org> wrote:
> Alexander Lazarevi&#263; uploaded a new version of Tools to project The Inbox:
> http://source.squeak.org/inbox/Tools-laza.218.mcz
>
> ==================== Summary ====================
>
> Name: Tools-laza.218
> Author: laza
> Time: 22 March 2010, 5:16:02.016 pm
> UUID: aa54427c-5fc5-4f5c-b283-deb2a7c85d5d
> Ancestors: Tools-laza.217
>
> Even if this does not find a majority and so is doomed for the dumpster:
> List instance vars alphabetically in an inspector.
>
> =============== Diff against Tools-laza.216 ===============
>
> Item was added:
> + ----- Method: Inspector>>instVarValueAt: (in category 'accessing') -----
> + instVarValueAt: anIndex
> +       ^ object instVarAt: (self instVarMap at: anIndex) value!
>
> Item was changed:
> + ----- Method: BasicInspector>>inspect: (in category 'initialize-release') -----
> - ----- Method: BasicInspector>>inspect: (in category 'as yet unclassified') -----
>  inspect: anObject
>        "Initialize the receiver so that it is inspecting anObject. There is no
>        current selection."
>
> -       self initialize.
>        object := anObject.
> +       self initialize.
>        selectionIndex := 0.
>        contents := ''!
>
> Item was changed:
>  ----- Method: Inspector>>selection (in category 'selecting') -----
>  selection
>        "The receiver has a list of variables of its inspected object.
>        One of these is selected. Answer the value of the selected variable."
>        | basicIndex |
>        selectionIndex = 0 ifTrue: [^ ''].
>        selectionIndex = 1 ifTrue: [^ object].
>        selectionIndex = 2 ifTrue: [^ object longPrintStringLimitedTo: 20000].
>        (selectionIndex - 2) <= object class instSize
> +               ifTrue: [^ self instVarValueAt: selectionIndex - 2].
> -               ifTrue: [^ object instVarAt: selectionIndex - 2].
>        basicIndex := selectionIndex - 2 - object class instSize.
>        (object basicSize <= (self i1 + self i2)  or: [basicIndex <= self i1])
>                ifTrue: [^ object basicAt: basicIndex]
>                ifFalse: [^ object basicAt: object basicSize - (self i1 + self i2) + basicIndex]!
>
> Item was added:
> + ----- Method: Inspector>>sortedInstVarMap (in category 'accessing') -----
> + sortedInstVarMap
> +       ^ self originalInstVarMap asSortedCollection!
>
> Item was added:
> + ----- Method: BasicInspector>>instVarMap (in category 'accessing') -----
> + instVarMap
> +       ^ self originalInstVarMap!
>
> Item was changed:
>  ----- Method: Inspector>>baseFieldList (in category 'accessing') -----
>  baseFieldList
>        "Answer an Array consisting of 'self'
>        and the instance variable names of the inspected object."
>
>        ^ (Array with: 'self' with: 'all inst vars')
> +                       , self instVarNames !
> -                       , object class allInstVarNames!
>
> Item was added:
> + ----- Method: Inspector>>originalInstVarMap (in category 'accessing') -----
> + originalInstVarMap
> +       ^ object class allInstVarNames withIndexCollect: [:each :idx | each -> idx]!
>
> Item was added:
> + ----- Method: Inspector>>instVarNames (in category 'accessing') -----
> + instVarNames
> +       ^ self instVarMap collect: [:each | each key]!
>
> Item was added:
> + ----- Method: Inspector>>defaultInstVarMap (in category 'accessing') -----
> + defaultInstVarMap
> +       ^ self sortedInstVarMap!
>
> Item was added:
> + ----- Method: Inspector>>instVarMap (in category 'accessing') -----
> + instVarMap
> +       ^ self sortedInstVarMap!
>
>
>



More information about the Squeak-dev mailing list