コミットメタ情報

リビジョン664a25f4527efc374642cfccbe8ae2de600c886a (tree)
日時2018-01-27 17:34:04
作者Kazuhiro Fujieda <fujieda@user...>
コミッターKazuhiro Fujieda

ログメッセージ

戦況のレイアウトを見直す

変更サマリ

差分

--- a/KancolleSniffer/BattleResultPanel.cs
+++ b/KancolleSniffer/BattleResultPanel.cs
@@ -156,7 +156,8 @@ namespace KancolleSniffer
156156 {
157157 foreach (var panel in _panelList)
158158 panel.Visible = false;
159- _rankLabel.Visible = _infomationPanel.Visible = false;
159+ _infomationPanel.Visible = false;
160+ _rankLabel.Text = "";
160161 }
161162
162163 private void ShowResult(BattleInfo.BattleResult result)
@@ -239,7 +240,7 @@ namespace KancolleSniffer
239240 _enemyLabels[0][1].Location.X + _enemyLabels.Max(labels => labels[1].Size.Width) - 1); // 敵の名前の右端
240241 for (var i = 0; i < lines; i++)
241242 _panelList[i].Width = panelWidth;
242- _infomationPanel.Location = new Point(AutoScrollPosition.X, 2 + AutoScrollPosition.Y);
243+ _infomationPanel.Location = new Point(AutoScrollPosition.X, AutoScrollPosition.Y);
243244 _infomationPanel.Visible = true;
244245 }
245246
@@ -266,7 +267,6 @@ namespace KancolleSniffer
266267
267268 private void ShowResultRank(BattleResultRank rank)
268269 {
269- _rankLabel.Visible = true;
270270 var result = new[] {"完全S", "勝利S", "勝利A", "勝利B", "敗北C", "敗北D", "敗北E"};
271271 _rankLabel.Text = result[(int)rank];
272272 }
@@ -275,20 +275,20 @@ namespace KancolleSniffer
275275 {
276276 _phaseLabel = new Label
277277 {
278- Location = new Point(78, 18),
278+ Location = new Point(72, 21),
279279 Size = new Size(31, 14)
280280 };
281281 _phaseLabel.Click += PhaseLabelClick;
282282 Controls.Add(_phaseLabel);
283283 _rankLabel = new Label
284284 {
285- Location = new Point(110, 18),
285+ Location = new Point(111, 22),
286286 Size = new Size(42, 12)
287287 };
288288 Controls.Add(_rankLabel);
289289 for (var i = 0; i < 14; i++)
290290 {
291- var y = LineHeight * (i + 1);
291+ var y = LineHeight * i + 21;
292292 var panel = new Panel
293293 {
294294 Location = new Point(0, y),
@@ -329,47 +329,53 @@ namespace KancolleSniffer
329329
330330 public InformationPanel()
331331 {
332+ const int top = 4;
333+ const int left = 1;
332334 Visible = false;
333- Size = new Size(213, 12);
335+ Size = new Size(left + 206, top + 15);
334336 Controls.AddRange(_formation = new[]
335337 {
336338 new Label
337339 {
338- Location = new Point(47, 0),
340+ Location = new Point(46, 0),
339341 Size = new Size(29, 12)
340342 },
341343 new Label
342344 {
343- Location = new Point(75, 0),
345+ Location = new Point(74, 0),
344346 Size = new Size(29, 12)
345347 },
346348 new Label
347349 {
348350 Location = new Point(0, 0),
349351 Size = new Size(48, 12),
350- TextAlign = ContentAlignment.MiddleRight
352+ TextAlign = ContentAlignment.MiddleCenter
351353 }
352354 });
353355 Controls.AddRange(_fighterPower = new[]
354356 {
355357 new Label
356358 {
357- Location = new Point(168, 0),
359+ Location = new Point(162, 0),
358360 Size = new Size(23, 12),
359361 TextAlign = ContentAlignment.MiddleRight
360362 },
361363 new Label
362364 {
363- Location = new Point(190, 0),
365+ Location = new Point(183, 0),
364366 Size = new Size(23, 12),
365367 TextAlign = ContentAlignment.MiddleRight
366368 },
367369 new Label
368370 {
369- Location = new Point(116, 0),
371+ Location = new Point(110, 0),
370372 Size = new Size(53, 12)
371373 }
372374 });
375+ foreach (Control control in Controls)
376+ control.Location = new Point(control.Location.X + left, control.Location.Y + top);
377+ // ReSharper disable once VirtualMemberCallInConstructor
378+ BackColor = ShipLabels.ColumnColors[1];
373379 }
374380
375381 public void SetInformation(BattleInfo battleInfo)
旧リポジトリブラウザで表示