DiffCodeView.st
author Stefan Vogel <sv@exept.de>
Fri, 17 May 2019 17:11:44 +0200
changeset 18767 0478d93cdb75
parent 12664 4369fcf7e557
child 12680 4e2f5b0d4cb2
permissions -rw-r--r--
#REFACTORING by stefan Sanitize BlockValues class: Tools::Inspector2 changed: #toolbarBackgroundHolder
Ignore whitespace changes - Everywhere: Within whitespace: At end of lines:
8094
52d72e2970f5 initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
     1
"
52d72e2970f5 initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
     2
 COPYRIGHT (c) 2008 by eXept Software AG
52d72e2970f5 initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
     3
              All Rights Reserved
52d72e2970f5 initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
     4
52d72e2970f5 initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
     5
 This software is furnished under a license and may be used
52d72e2970f5 initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
     6
 only in accordance with the terms of that license and with the
52d72e2970f5 initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
     7
 inclusion of the above copyright notice.   This software may not
52d72e2970f5 initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
     8
 be provided or otherwise made available to, or used by, any
52d72e2970f5 initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
     9
 other person.  No title to or ownership of the software is
52d72e2970f5 initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
    10
 hereby transferred.
52d72e2970f5 initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
    11
"
52d72e2970f5 initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
    12
"{ Package: 'stx:libtool' }"
52d72e2970f5 initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
    13
52d72e2970f5 initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
    14
DiffTextView subclass:#DiffCodeView
52d72e2970f5 initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
    15
	instanceVariableNames:''
52d72e2970f5 initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
    16
	classVariableNames:''
52d72e2970f5 initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
    17
	poolDictionaries:''
52d72e2970f5 initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
    18
	category:'Views-Text'
52d72e2970f5 initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
    19
!
52d72e2970f5 initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
    20
52d72e2970f5 initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
    21
!DiffCodeView class methodsFor:'documentation'!
52d72e2970f5 initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
    22
52d72e2970f5 initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
    23
copyright
52d72e2970f5 initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
    24
"
52d72e2970f5 initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
    25
 COPYRIGHT (c) 2008 by eXept Software AG
52d72e2970f5 initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
    26
              All Rights Reserved
52d72e2970f5 initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
    27
52d72e2970f5 initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
    28
 This software is furnished under a license and may be used
52d72e2970f5 initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
    29
 only in accordance with the terms of that license and with the
52d72e2970f5 initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
    30
 inclusion of the above copyright notice.   This software may not
52d72e2970f5 initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
    31
 be provided or otherwise made available to, or used by, any
52d72e2970f5 initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
    32
 other person.  No title to or ownership of the software is
52d72e2970f5 initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
    33
 hereby transferred.
52d72e2970f5 initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
    34
"
52d72e2970f5 initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
    35
!
52d72e2970f5 initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
    36
52d72e2970f5 initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
    37
documentation
52d72e2970f5 initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
    38
"
52d72e2970f5 initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
    39
    a view which presents two CodeViews for diffing.
52d72e2970f5 initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
    40
    Like a regular diffTextView, but the codeViews show a code-aware popUpMenu.
52d72e2970f5 initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
    41
52d72e2970f5 initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
    42
    [see also:]
52d72e2970f5 initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
    43
        TwoColumnTextView DiffTextView
52d72e2970f5 initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
    44
52d72e2970f5 initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
    45
    [author:]
52d72e2970f5 initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
    46
        Claus Gittinger
52d72e2970f5 initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
    47
"
52d72e2970f5 initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
    48
! !
52d72e2970f5 initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
    49
52d72e2970f5 initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
    50
!DiffCodeView class methodsFor:'defaults'!
52d72e2970f5 initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
    51
52d72e2970f5 initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
    52
textViewClass
52d72e2970f5 initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
    53
    "return the type of the synced subViews.
52d72e2970f5 initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
    54
     Redefined to use a CodeView"
52d72e2970f5 initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
    55
52d72e2970f5 initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
    56
    ^ CodeView
52d72e2970f5 initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
    57
! !
52d72e2970f5 initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
    58
12664
4369fcf7e557 class: DiffCodeView
Claus Gittinger <cg@exept.de>
parents: 8094
diff changeset
    59
!DiffCodeView methodsFor:'initialization'!
4369fcf7e557 class: DiffCodeView
Claus Gittinger <cg@exept.de>
parents: 8094
diff changeset
    60
4369fcf7e557 class: DiffCodeView
Claus Gittinger <cg@exept.de>
parents: 8094
diff changeset
    61
initialize
4369fcf7e557 class: DiffCodeView
Claus Gittinger <cg@exept.de>
parents: 8094
diff changeset
    62
    super initialize.
4369fcf7e557 class: DiffCodeView
Claus Gittinger <cg@exept.de>
parents: 8094
diff changeset
    63
4369fcf7e557 class: DiffCodeView
Claus Gittinger <cg@exept.de>
parents: 8094
diff changeset
    64
    textViews doWithIndex:[:v :i |
4369fcf7e557 class: DiffCodeView
Claus Gittinger <cg@exept.de>
parents: 8094
diff changeset
    65
        v readOnly:true.
4369fcf7e557 class: DiffCodeView
Claus Gittinger <cg@exept.de>
parents: 8094
diff changeset
    66
        "/ v acceptAction:[:text | self acceptInView:i ]
4369fcf7e557 class: DiffCodeView
Claus Gittinger <cg@exept.de>
parents: 8094
diff changeset
    67
    ].
4369fcf7e557 class: DiffCodeView
Claus Gittinger <cg@exept.de>
parents: 8094
diff changeset
    68
!
4369fcf7e557 class: DiffCodeView
Claus Gittinger <cg@exept.de>
parents: 8094
diff changeset
    69
4369fcf7e557 class: DiffCodeView
Claus Gittinger <cg@exept.de>
parents: 8094
diff changeset
    70
leftAcceptAction:aOneArgBlock
4369fcf7e557 class: DiffCodeView
Claus Gittinger <cg@exept.de>
parents: 8094
diff changeset
    71
    (textViews at:1) acceptAction:aOneArgBlock
4369fcf7e557 class: DiffCodeView
Claus Gittinger <cg@exept.de>
parents: 8094
diff changeset
    72
!
4369fcf7e557 class: DiffCodeView
Claus Gittinger <cg@exept.de>
parents: 8094
diff changeset
    73
4369fcf7e557 class: DiffCodeView
Claus Gittinger <cg@exept.de>
parents: 8094
diff changeset
    74
rightAcceptAction:aOneArgBlock
4369fcf7e557 class: DiffCodeView
Claus Gittinger <cg@exept.de>
parents: 8094
diff changeset
    75
    (textViews at:2) acceptAction:aOneArgBlock
4369fcf7e557 class: DiffCodeView
Claus Gittinger <cg@exept.de>
parents: 8094
diff changeset
    76
! !
4369fcf7e557 class: DiffCodeView
Claus Gittinger <cg@exept.de>
parents: 8094
diff changeset
    77
8094
52d72e2970f5 initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
    78
!DiffCodeView class methodsFor:'documentation'!
52d72e2970f5 initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
    79
52d72e2970f5 initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
    80
version
12664
4369fcf7e557 class: DiffCodeView
Claus Gittinger <cg@exept.de>
parents: 8094
diff changeset
    81
    ^ '$Header: /cvs/stx/stx/libtool/DiffCodeView.st,v 1.2 2013-04-14 18:10:35 cg Exp $'
8094
52d72e2970f5 initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
    82
! !
12664
4369fcf7e557 class: DiffCodeView
Claus Gittinger <cg@exept.de>
parents: 8094
diff changeset
    83