Menu

#310 Add a sorting functionality to the duplicate code dialogue

v1.1.x
closed
None
v1.1.1
New Functionality
2018-04-25
2018-04-12
Erik Hänel
No

Add a sorting functionality for the columns of to the duplicate code dialogue.

Analysis:
A custom handler has to be implemented because wxListCtrl doesn't support column-specific sorting. One may use the std::stable_sort from <algorithm>. To allow to return the sorting index rather than sorting the column itself, one has to implement a sorting struct, which overrides the int operator()(int, int) (see https://phoxis.org/2012/07/12/get-sorted-index-orderting-of-an-array/).

Implementation:
The functionality was implemented as proposed by the analysis. Implementation tests were passed successfully.

Documentation:
The new functionality was documented in the changes log. Further documentation not needed, because it is a self-explaining feature.

Tests:
The functionality was tested and no deviations were detected. New functionality implemented successfully.

Discussion

  • Erik Hänel

    Erik Hänel - 2018-04-14
    • status: open --> accepted
     
  • Erik Hänel

    Erik Hänel - 2018-04-14
    • Description has changed:

    Diff:

    --- old
    +++ new
    @@ -1 +1,9 @@
     Add a sorting functionality for the columns of to the duplicate code dialogue.
    +
    +**Analysis:**
    +
    +**Implementation:**
    +
    +**Documentation:**
    +
    +**Tests:**
    
    • status: accepted --> analyzing
     
  • Erik Hänel

    Erik Hänel - 2018-04-15
    • Description has changed:

    Diff:

    --- old
    +++ new
    @@ -1,6 +1,7 @@
     Add a sorting functionality for the columns of to the duplicate code dialogue.
    
     **Analysis:**
    +A custom handler has to be implemented because wxListCtrl doesn't support column-specific sorting. One may use the `std::stable_sort` from `<algorithm>`. To allow to return the sorting index rather than sorting the column itself, one has to implement a sorting struct, which overrides the `int operator()(int, int)` (see https://phoxis.org/2012/07/12/get-sorted-index-orderting-of-an-array/).
    
     **Implementation:**
    
    • status: analyzing --> implementing
     
  • Erik Hänel

    Erik Hänel - 2018-04-15
    • Description has changed:

    Diff:

    --- old
    +++ new
    @@ -4,7 +4,9 @@
     A custom handler has to be implemented because wxListCtrl doesn't support column-specific sorting. One may use the `std::stable_sort` from `<algorithm>`. To allow to return the sorting index rather than sorting the column itself, one has to implement a sorting struct, which overrides the `int operator()(int, int)` (see https://phoxis.org/2012/07/12/get-sorted-index-orderting-of-an-array/).
    
     **Implementation:**
    +The functionality was implemented as proposed by the analysis. Implementation tests were passed successfully.
    
     **Documentation:**
    +The new functionality was documented in the changes log. Further documentation not needed, because it is a self-explaining feature.
    
     **Tests:**
    
    • status: implementing --> testing
     
  • Erik Hänel

    Erik Hänel - 2018-04-25
    • Description has changed:

    Diff:

    --- old
    +++ new
    @@ -10,3 +10,4 @@
     The new functionality was documented in the changes log. Further documentation not needed, because it is a self-explaining feature.
    
     **Tests:**
    +The functionality was tested and no deviations were detected. New functionality implemented successfully.
    
    • status: testing --> closed
     

Anonymous
Anonymous

Add attachments
Cancel