質問編集履歴
2
コードの変更
test
CHANGED
File without changes
|
test
CHANGED
@@ -50,113 +50,129 @@
|
|
50
50
|
|
51
51
|
if counter == 2{
|
52
52
|
|
53
|
+
self.performSegue(withIdentifier: "goFirstSegue", sender: nil)
|
54
|
+
|
55
|
+
counter = 0
|
56
|
+
|
57
|
+
}
|
58
|
+
|
59
|
+
// 遷移するViewを定義する.このas!はswift1.2では as?だったかと。
|
60
|
+
|
61
|
+
let FirstViewController: FirstViewController = self.storyboard?.instantiateViewController(withIdentifier: "goFirstViewSegue") as! FirstViewController
|
62
|
+
|
63
|
+
// Viewの移動する.
|
64
|
+
|
65
|
+
self.MenutViewController(MenuViewController, animated: true, completion: nil)
|
66
|
+
|
67
|
+
}
|
68
|
+
|
69
|
+
|
70
|
+
|
71
|
+
@IBAction func Buzzvideo(_ sender: UIButton)
|
72
|
+
|
73
|
+
{
|
74
|
+
|
75
|
+
counter = counter + 1
|
76
|
+
|
77
|
+
print(counter)
|
78
|
+
|
79
|
+
|
80
|
+
|
81
|
+
if counter == 2{
|
82
|
+
|
83
|
+
self.performSegue(withIdentifier: "goFirstSegue2", sender: nil)
|
84
|
+
|
85
|
+
counter = 0
|
86
|
+
|
87
|
+
}
|
88
|
+
|
89
|
+
}
|
90
|
+
|
91
|
+
@IBAction func Instagram(_ sender: UIButton)
|
92
|
+
|
93
|
+
{
|
94
|
+
|
95
|
+
counter = counter + 1
|
96
|
+
|
97
|
+
print(counter)
|
98
|
+
|
99
|
+
|
100
|
+
|
101
|
+
if counter == 2{
|
102
|
+
|
103
|
+
self.performSegue(withIdentifier: "goFirstSegue3", sender: nil)
|
104
|
+
|
105
|
+
counter = 0
|
106
|
+
|
107
|
+
}
|
108
|
+
|
109
|
+
}
|
110
|
+
|
111
|
+
@IBAction func Twitter(_ sender: UIButton)
|
112
|
+
|
113
|
+
{
|
114
|
+
|
115
|
+
counter = counter + 1
|
116
|
+
|
117
|
+
print(counter)
|
118
|
+
|
119
|
+
|
120
|
+
|
121
|
+
if counter == 2{
|
122
|
+
|
123
|
+
self.performSegue(withIdentifier: "goFirstSegue4", sender: nil)
|
124
|
+
|
125
|
+
counter = 0
|
126
|
+
|
127
|
+
}
|
128
|
+
|
129
|
+
}
|
130
|
+
|
131
|
+
@IBAction func niconico(_ sender: UIButton)
|
132
|
+
|
133
|
+
{
|
134
|
+
|
135
|
+
counter = counter + 1
|
136
|
+
|
137
|
+
print(counter)
|
138
|
+
|
139
|
+
|
140
|
+
|
141
|
+
if counter == 2{
|
142
|
+
|
143
|
+
self.performSegue(withIdentifier: "goFirstSegue5", sender: nil)
|
144
|
+
|
145
|
+
counter = 0
|
146
|
+
|
147
|
+
}
|
148
|
+
|
149
|
+
}
|
150
|
+
|
151
|
+
|
152
|
+
|
153
|
+
|
154
|
+
|
155
|
+
override func viewDidLoad() {
|
156
|
+
|
157
|
+
super.viewDidLoad()
|
158
|
+
|
159
|
+
|
160
|
+
|
161
|
+
menuView.delegate = self
|
162
|
+
|
163
|
+
menuView.dataSource = self
|
164
|
+
|
165
|
+
|
166
|
+
|
53
167
|
self.performSegue(withIdentifier: "goFirstViewSegue", sender: nil)
|
54
168
|
|
55
|
-
counter = 0
|
56
|
-
|
57
|
-
|
169
|
+
}
|
58
|
-
|
59
|
-
|
170
|
+
|
60
|
-
|
61
|
-
|
62
|
-
|
63
|
-
|
171
|
+
override func prepare(for segue: UIStoryboardSegue, sender: Any?)
|
64
|
-
|
172
|
+
|
65
|
-
{
|
173
|
+
{
|
66
|
-
|
67
|
-
|
174
|
+
|
68
|
-
|
69
|
-
print(counter)
|
70
|
-
|
71
|
-
|
72
|
-
|
73
|
-
if counter == 2{
|
74
|
-
|
75
|
-
self.performSegue(withIdentifier: "goFirstSegue2", sender: nil)
|
76
|
-
|
77
|
-
counter = 0
|
78
|
-
|
79
|
-
}
|
80
|
-
|
81
|
-
}
|
82
|
-
|
83
|
-
@IBAction func Instagram(_ sender: UIButton)
|
84
|
-
|
85
|
-
{
|
86
|
-
|
87
|
-
counter = counter + 1
|
88
|
-
|
89
|
-
print(counter)
|
90
|
-
|
91
|
-
|
92
|
-
|
93
|
-
if counter == 2{
|
94
|
-
|
95
|
-
self.performSegue(withIdentifier: "goFirstViewSegue3", sender: nil)
|
96
|
-
|
97
|
-
counter = 0
|
98
|
-
|
99
|
-
}
|
100
|
-
|
101
|
-
}
|
102
|
-
|
103
|
-
@IBAction func Twitter(_ sender: UIButton)
|
104
|
-
|
105
|
-
{
|
106
|
-
|
107
|
-
counter = counter + 1
|
108
|
-
|
109
|
-
print(counter)
|
110
|
-
|
111
|
-
|
112
|
-
|
113
|
-
if counter == 2{
|
114
|
-
|
115
|
-
self.performSegue(withIdentifier: "goFirstViewSegue4", sender: nil)
|
116
|
-
|
117
|
-
counter = 0
|
118
|
-
|
119
|
-
}
|
120
|
-
|
121
|
-
}
|
122
|
-
|
123
|
-
@IBAction func niconico(_ sender: UIButton)
|
124
|
-
|
125
|
-
{
|
126
|
-
|
127
|
-
counter = counter + 1
|
128
|
-
|
129
|
-
print(counter)
|
130
|
-
|
131
|
-
|
132
|
-
|
133
|
-
if counter == 2{
|
134
|
-
|
135
|
-
self.performSegue(withIdentifier: "goFirstViewSegue5", sender: nil)
|
136
|
-
|
137
|
-
counter = 0
|
138
|
-
|
139
|
-
}
|
140
|
-
|
141
|
-
}
|
142
|
-
|
143
|
-
|
144
|
-
|
145
|
-
|
146
|
-
|
147
|
-
override func viewDidLoad() {
|
148
|
-
|
149
|
-
super.viewDidLoad()
|
150
|
-
|
151
|
-
|
152
|
-
|
153
|
-
menuView.delegate = self
|
154
|
-
|
155
|
-
menuView.dataSource = self
|
156
|
-
|
157
|
-
|
158
|
-
|
159
|
-
|
175
|
+
if (segue.identifier == "goFirstViewSegue"){}
|
160
176
|
|
161
177
|
}
|
162
178
|
|
@@ -172,15 +188,17 @@
|
|
172
188
|
|
173
189
|
|
174
190
|
|
175
|
-
// Segue 準備
|
176
|
-
|
177
|
-
|
191
|
+
func menuView(_ tableView: UITableView, didSelectRowAt indexPath: IndexPath)
|
192
|
+
|
178
|
-
|
193
|
+
{
|
194
|
+
|
195
|
+
let cell = menuView.cellForRow(at: indexPath)
|
196
|
+
|
179
|
-
let n
|
197
|
+
let indicator = cell?.contentView.viewWithTag(1) as! UIActivityIndicatorView
|
180
|
-
|
181
|
-
|
198
|
+
|
182
|
-
|
183
|
-
n
|
199
|
+
indicator.startAnimating()
|
200
|
+
|
201
|
+
|
184
202
|
|
185
203
|
}
|
186
204
|
|
@@ -304,4 +322,8 @@
|
|
304
322
|
|
305
323
|
|
306
324
|
|
325
|
+
|
326
|
+
|
327
|
+
|
328
|
+
|
307
329
|
```
|
1
情報の補足
test
CHANGED
File without changes
|
test
CHANGED
@@ -1,4 +1,12 @@
|
|
1
|
+
> storyboardの画像です
|
2
|
+
|
3
|
+
![イメージ説明](70a939493f185954bcfa4c3d513c5df3.png)
|
4
|
+
|
5
|
+
|
6
|
+
|
7
|
+
|
8
|
+
|
1
|
-
|
9
|
+
MenuViewControllerにあるサイドメニューからいくつかあるブラウザを選択しFirstViewControllerにあるWKWebViewに表示させたいです。
|
2
10
|
|
3
11
|
問題点はサイドメニュー内にあるセルをタップしたときに対応する値を配列から取得しWKWebViewに表示するところで困っています。コード内の//セルが選択された時と//Segue 準備のところで
|
4
12
|
|