回答編集履歴

2

コードの間違い訂正

2022/11/14 15:16

投稿

teamikl
teamikl

スコア8664

test CHANGED
@@ -82,5 +82,5 @@
82
82
  ```python
83
83
  def focusNext(event):
84
84
  index = w_list.index(event.widget)
85
- w_list[(index + 1) % len(w_list)].next()
85
+ w_list[(index + 1) % len(w_list)].focus()
86
86
  ```

1

コード修正

2022/11/14 07:31

投稿

teamikl
teamikl

スコア8664

test CHANGED
@@ -66,7 +66,7 @@
66
66
  def nextFocus(event):
67
67
  global count
68
68
  count = (count + 1) % len(w_list)
69
- w_list[count].next()
69
+ w_list[count].focus()
70
70
  ```
71
71
 
72
72
  デメリット: 外部でカウントの為の変数を管理しなければなりません。