mirror of
				https://github.com/taigrr/wtf
				synced 2025-01-18 04:03:14 -08:00 
			
		
		
		
	
						commit
						9e7045ca52
					
				@ -1,7 +1,5 @@
 | 
			
		||||
package todo
 | 
			
		||||
 | 
			
		||||
import ()
 | 
			
		||||
 | 
			
		||||
type List struct {
 | 
			
		||||
	Items []*Item
 | 
			
		||||
 | 
			
		||||
@ -33,10 +31,7 @@ func (list *List) CheckedItems() []*Item {
 | 
			
		||||
 | 
			
		||||
func (list *List) Delete() {
 | 
			
		||||
	list.Items = append(list.Items[:list.selected], list.Items[list.selected+1:]...)
 | 
			
		||||
 | 
			
		||||
	if list.selected >= len(list.Items) {
 | 
			
		||||
		list.selected--
 | 
			
		||||
	}
 | 
			
		||||
	list.Prev()
 | 
			
		||||
}
 | 
			
		||||
 | 
			
		||||
func (list *List) Demote() {
 | 
			
		||||
 | 
			
		||||
		Loading…
	
	
			
			x
			
			
		
	
		Reference in New Issue
	
	Block a user