// File: /workspace/github_c_makefile_star2_O1/enzo1982[P]smooth/classes/gui/dialogs/tipodaydlg.cpp
// Function: smooth::GUI::Dialogs::TipOfTheDay::TipOfTheDay(bool*)
S::GUI::Dialogs::TipOfTheDay::TipOfTheDay(Bool *iShowTips)
{
	showTips = iShowTips;

	mode = TIP_ORDERED;
	offset = 0;

	dlgwnd		= new Window(I18n::Translator::defaultTranslator->TranslateString("Tip of the day"), Point(200, 200), Size(350, 300));

	titlebar	= new Titlebar(TB_CLOSEBUTTON);
	divbar		= new Divider(39, OR_HORZ | OR_BOTTOM);

	btn_ok		= new Button(I18n::Translator::defaultTranslator->TranslateString("OK"), Point(87, 29), Size());
	btn_ok->onAction.Connect(&TipOfTheDay::OnOK, this);
	btn_ok->SetOrientation(OR_LOWERRIGHT);

	btn_next	= new Button(I18n::Translator::defaultTranslator->TranslateString("Next tip"), Point(175, 29), Size());
	btn_next->onAction.Connect(&TipOfTheDay::OnNext, this);
	btn_next->SetOrientation(OR_LOWERRIGHT);
	btn_next->SetWidth(Math::Max(80, btn_next->GetUnscaledTextWidth() + 13));
	btn_next->SetX(btn_next->GetWidth() + 95);

	check_showtips	= new CheckBox(I18n::Translator::defaultTranslator->TranslateString("Show tips on startup"), Point(7, 27), Size(150, 0), showTips);
	check_showtips->SetOrientation(OR_LOWERLEFT);
	check_showtips->SetWidth(check_showtips->GetUnscaledTextWidth() + 21);

	Buffer<UnsignedByte> light(sizeof(Icons::Light));

	memcpy(light, Icons::Light, sizeof(Icons::Light));

	img_light	= new Image(ImageLoader::Load(light, IMAGE_FORMAT_PNG), Point(8, 3), Size(32, 32));

	txt_didyouknow	= new Text(I18n::Translator::defaultTranslator->TranslateString("Did you know..."), Point(11 + img_light->GetWidth(), 7));
	txt_didyouknow->SetFont(Font(Font::Default, 14, Font::Bold, 0, txt_didyouknow->GetFont().GetColor()));

	txt_tip		= new Cursor(Point(6, 4), Size(328, 182));
	txt_tip->SetFont(Font(Font::Default, Font::DefaultSize, Font::Normal, 0, Setup::TooltipTextColor));
	txt_tip->SetFlags(CF_MULTILINE);
	txt_tip->Deactivate();

	layer_inner	= new Layer();
	layer_inner->SetMetrics(Point(8, 39), Size(328, 182));
	layer_inner->SetBackgroundColor(Setup::TooltipColor);

	Add(dlgwnd);

	dlgwnd->Add(titlebar);
	dlgwnd->Add(divbar);

	dlgwnd->Add(btn_ok);
	dlgwnd->Add(btn_next);
	dlgwnd->Add(check_showtips);

	dlgwnd->Add(img_light);
	dlgwnd->Add(txt_didyouknow);

	dlgwnd->GetMainLayer()->Add(layer_inner);

	layer_inner->Add(txt_tip);

	dlgwnd->SetFlags(dlgwnd->GetFlags() | WF_MODAL);
	dlgwnd->onPaint.Connect(&TipOfTheDay::OnPaint, this);
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x68, %rsp
movq %rsi, %r15
movq %rdi, %rbx
callq 0x57650
movq 0x101174(%rip), %rax    # 0x16cf60
addq $0x10, %rax
movq %rax, (%rbx)
leaq 0x640(%rbx), %r14
movq %r14, %rdi
callq 0x55d90
leaq 0xf5487(%rip), %rax     # 0x161290
movq %rax, 0x680(%rbx)
xorps %xmm0, %xmm0
movups %xmm0, 0x688(%rbx)
leaq 0xf53cf(%rip), %rax     # 0x1611f0
movq %rax, 0x640(%rbx)
movq %r15, 0x638(%rbx)
movq $0x0, 0x698(%rbx)
movl $0x6d8, %edi            # imm = 0x6D8
callq 0x556b0
movq %rax, %r12
movq 0x10059a(%rip), %r13    # 0x16c3e8
movq (%r13), %r15
leaq 0x88cde(%rip), %rsi     # 0xf4b37
leaq 0x8(%rsp), %rdi
callq 0x579f0
leaq 0x8(%rsp), %rsi
movq %r15, %rdi
callq 0x58260
movabsq $0xc8000000c8, %rcx     # imm = 0xC8000000C8
leaq 0x48(%rsp), %rdx
movq %rcx, (%rdx)
movabsq $0x12c0000015e, %rsi    # imm = 0x12C0000015E
movq %rsp, %rcx
movq %rsi, (%rcx)
movq %r12, %rdi
movq %rax, %rsi
xorl %r8d, %r8d
callq 0x56fe0
movq %r12, 0x5e8(%rbx)
leaq 0x8(%rsp), %rdi
callq 0x59200
movl $0x5c8, %edi            # imm = 0x5C8
callq 0x556b0
movq %rax, %r12
movq %rax, %rdi
movl $0x4, %esi
callq 0x56390
movq %r12, 0x5f0(%rbx)
movl $0x5f8, %edi            # imm = 0x5F8
callq 0x556b0
movq %rax, %r12
movq %rax, %rdi
movl $0x27, %esi
movl $0x9, %edx
callq 0x56b70
movq %r12, 0x5f8(%rbx)
movl $0x5c8, %edi            # imm = 0x5C8
callq 0x556b0
movq %rax, %r12
movq (%r13), %r15
leaq 0xc3044(%rip), %rsi     # 0x12ef54
leaq 0x8(%rsp), %rdi
callq 0x579f0
leaq 0x8(%rsp), %rsi
movq %r15, %rdi
callq 0x58260
movabsq $0x1d00000057, %rcx     # imm = 0x1D00000057
leaq 0x48(%rsp), %rdx
movq %rcx, (%rdx)
movq %rsp, %rcx
movq $0x0, (%rcx)
movq %r12, %rdi
movq %rax, %rsi
callq 0x573b0
movq %r12, 0x600(%rbx)
leaq 0x8(%rsp), %rdi
callq 0x59200
movl $0x478, %edi            # imm = 0x478
addq 0x600(%rbx), %rdi
movq 0x1006de(%rip), %rsi    # 0x16c650
xorl %edx, %edx
movq %rbx, %rcx
callq 0x6cbf4
movq 0x600(%rbx), %rdi
movq (%rdi), %rax
movl $0x28, %esi
callq *0x120(%rax)
movl $0x5c8, %edi            # imm = 0x5C8
callq 0x556b0
movq %rax, %r12
movq (%r13), %r15
leaq 0x88b9d(%rip), %rsi     # 0xf4b46
leaq 0x8(%rsp), %rdi
callq 0x579f0
leaq 0x8(%rsp), %rsi
movq %r15, %rdi
callq 0x58260
movabsq $0x1d000000af, %rcx     # imm = 0x1D000000AF
leaq 0x48(%rsp), %rdx
movq %rcx, (%rdx)
movq %rsp, %rcx
movq $0x0, (%rcx)
movq %r12, %rdi
movq %rax, %rsi
callq 0x573b0
movq %r12, 0x608(%rbx)
leaq 0x8(%rsp), %rdi
callq 0x59200
movl $0x478, %edi            # imm = 0x478
addq 0x608(%rbx), %rdi
movq 0x100a1d(%rip), %rsi    # 0x16ca28
xorl %edx, %edx
movq %rbx, %rcx
callq 0x6cbf4
movq 0x608(%rbx), %rdi
movq (%rdi), %rax
movl $0x28, %esi
callq *0x120(%rax)
movq 0x608(%rbx), %r15
movq (%r15), %rax
movq %r15, %rdi
callq *0xf0(%rax)
cmpl $0x44, %eax
movl $0x43, %ecx
cmovgel %eax, %ecx
addl $0xd, %ecx
leaq 0xa8(%r15), %rsi
movl 0xb4(%r15), %eax
leaq 0x8(%rsp), %rdx
movl %ecx, (%rdx)
movl %eax, 0x4(%rdx)
movq (%r15), %rax
movq %r15, %rdi
callq *0x150(%rax)
movq 0x608(%rbx), %rdi
leaq 0xb0(%rdi), %rdx
movl 0xb0(%rdi), %eax
addl $0x5f, %eax
movl 0xac(%rdi), %ecx
leaq 0x8(%rsp), %rsi
movl %eax, (%rsi)
movl %ecx, 0x4(%rsi)
movq (%rdi), %rax
callq *0x150(%rax)
movl $0x5d8, %edi            # imm = 0x5D8
callq 0x556b0
movq %rax, %r12
movq (%r13), %r15
leaq 0x88a98(%rip), %rsi     # 0xf4b4f
leaq 0x8(%rsp), %rdi
callq 0x579f0
leaq 0x8(%rsp), %rsi
movq %r15, %rdi
callq 0x58260
movabsq $0x1b00000007, %rcx     # imm = 0x1B00000007
leaq 0x48(%rsp), %rdx
movq %rcx, (%rdx)
movq %rsp, %rcx
movq $0x96, (%rcx)
movq 0x638(%rbx), %r8
movq %r12, %rdi
movq %rax, %rsi
callq 0x55b10
movq %r12, 0x610(%rbx)
leaq 0x8(%rsp), %rdi
callq 0x59200
movq 0x610(%rbx), %rdi
movq (%rdi), %rax
movl $0x18, %esi
callq *0x120(%rax)
movq 0x610(%rbx), %r15
movq (%r15), %rax
movq %r15, %rdi
callq *0xf0(%rax)
addl $0x15, %eax
leaq 0xa8(%r15), %rsi
movl 0xb4(%r15), %ecx
leaq 0x8(%rsp), %rdx
movl %eax, (%rdx)
movl %ecx, 0x4(%rdx)
movq (%r15), %rax
movq %r15, %rdi
callq *0x150(%rax)
leaq 0x48(%rsp), %rdi
movl $0x1b27, %esi           # imm = 0x1B27
callq 0x62006
movq 0x50(%rsp), %rax
movq (%rax), %rdi
leaq 0x88ab6(%rip), %rsi     # 0xf4c30
movl $0x1b27, %edx           # imm = 0x1B27
callq 0x552d0
movl $0x5c8, %edi            # imm = 0x5C8
callq 0x556b0
movq %rax, %r12
leaq 0x8(%rsp), %rdi
leaq 0x48(%rsp), %rsi
movl $0x1, %edx
callq 0x57d30
movabsq $0x300000008, %rax      # imm = 0x300000008
movq %rsp, %rdx
movq %rax, (%rdx)
movabsq $0x2000000020, %rax     # imm = 0x2000000020
leaq 0x60(%rsp), %rcx
movq %rax, (%rcx)
leaq 0x8(%rsp), %rsi
movq %r12, %rdi
callq 0x55980
movq %r12, 0x618(%rbx)
leaq 0x8(%rsp), %rdi
callq 0x59148
movl $0x5c0, %edi            # imm = 0x5C0
callq 0x556b0
movq %rax, %r12
movq (%r13), %r15
leaq 0x88967(%rip), %rsi     # 0xf4b64
leaq 0x8(%rsp), %rdi
callq 0x579f0
leaq 0x8(%rsp), %rsi
movq %r15, %rdi
callq 0x58260
movq 0x618(%rbx), %rcx
movl 0xb0(%rcx), %ecx
addl $0xb, %ecx
movq %rsp, %rdx
movl %ecx, (%rdx)
movl $0x7, 0x4(%rdx)
leaq 0x60(%rsp), %rcx
movq $0x0, (%rcx)
movq %r12, %rdi
movq %rax, %rsi
callq 0x55a00
movq %r12, 0x620(%rbx)
leaq 0x8(%rsp), %rdi
callq 0x59200
movq 0x620(%rbx), %r15
movq 0x1001e2(%rip), %rax    # 0x16c448
movzwl (%rax), %ebp
movq (%r15), %rax
movq %r15, %rdi
callq *0xe8(%rax)
movq %rax, %rdi
callq 0x57550
movswl %bp, %ecx
movq 0x100b31(%rip), %rsi    # 0x16cdb8
leaq 0x8(%rsp), %rdi
movl $0xe, %edx
xorl %r8d, %r8d
movq %rax, %r9
callq 0x57270
movq (%r15), %rax
leaq 0x8(%rsp), %rsi
movq %r15, %rdi
callq *0xe0(%rax)
leaq 0x8(%rsp), %rdi
callq 0x56720
movl $0x768, %edi            # imm = 0x768
callq 0x556b0
movq %rax, %r12
movabsq $0x400000006, %rax      # imm = 0x400000006
leaq 0x8(%rsp), %rsi
movq %rax, (%rsi)
movabsq $0xb600000148, %r13     # imm = 0xB600000148
movq %rsp, %rdx
movq %r13, (%rdx)
movq %r12, %rdi
callq 0x55c70
movq %r12, 0x628(%rbx)
movq 0x100b9c(%rip), %rax    # 0x16ce98
movswl (%rax), %edx
movq 0x10047a(%rip), %rax    # 0x16c780
movswl (%rax), %ecx
movq 0x100aa8(%rip), %rsi    # 0x16cdb8
movq 0x100579(%rip), %r9     # 0x16c890
leaq 0x8(%rsp), %rdi
xorl %r8d, %r8d
callq 0x57270
movq (%r12), %rax
leaq 0x8(%rsp), %rsi
movq %r12, %rdi
callq *0xe0(%rax)
leaq 0x8(%rsp), %rdi
callq 0x56720
movq 0x628(%rbx), %rdi
movl $0x1, 0x30(%rdi)
movq (%rdi), %rax
callq *0x70(%rax)
movl $0x5b8, %edi            # imm = 0x5B8
callq 0x556b0
movq %rax, %r12
leaq 0x8(%rsp), %rdi
xorl %esi, %esi
callq 0x58e20
leaq 0x8(%rsp), %rsi
movq %r12, %rdi
callq 0x56a90
movq %r12, 0x630(%rbx)
leaq 0x8(%rsp), %r15
movq %r15, %rdi
callq 0x59200
movq 0x630(%rbx), %rdi
movabsq $0x2700000008, %rax     # imm = 0x2700000008
movq %rax, (%r15)
movq %rsp, %rdx
movq %r13, (%rdx)
movq (%rdi), %rax
leaq 0x8(%rsp), %rsi
callq *0x150(%rax)
movq 0x630(%rbx), %rdi
movq (%rdi), %rax
movq 0x100139(%rip), %rsi    # 0x16c500
callq *0x138(%rax)
movq 0x5e8(%rbx), %rsi
movq (%rbx), %rax
movq %rbx, %rdi
callq *0x30(%rax)
movq 0x5e8(%rbx), %rdi
movq 0x5f0(%rbx), %rsi
movq (%rdi), %rax
callq *0x30(%rax)
movq 0x5e8(%rbx), %rdi
movq 0x5f8(%rbx), %rsi
movq (%rdi), %rax
callq *0x30(%rax)
movq 0x5e8(%rbx), %rdi
movq 0x600(%rbx), %rsi
movq (%rdi), %rax
callq *0x30(%rax)
movq 0x5e8(%rbx), %rdi
movq 0x608(%rbx), %rsi
movq (%rdi), %rax
callq *0x30(%rax)
movq 0x5e8(%rbx), %rdi
movq 0x610(%rbx), %rsi
movq (%rdi), %rax
callq *0x30(%rax)
movq 0x5e8(%rbx), %rdi
movq 0x618(%rbx), %rsi
movq (%rdi), %rax
callq *0x30(%rax)
movq 0x5e8(%rbx), %rdi
movq 0x620(%rbx), %rsi
movq (%rdi), %rax
callq *0x30(%rax)
movq 0x5e8(%rbx), %rax
movq 0x630(%rbx), %rsi
movq 0x620(%rax), %rdi
movq (%rdi), %rax
callq *0x30(%rax)
movq 0x628(%rbx), %rsi
movq 0x630(%rbx), %rdi
movq (%rdi), %rax
callq *0x30(%rax)
movq 0x5e8(%rbx), %rdi
orl $0x1, 0x30(%rdi)
addq $0x648, %rdi            # imm = 0x648
movq 0x100477(%rip), %rsi    # 0x16c928
xorl %edx, %edx
movq %rbx, %rcx
callq 0x6cbf4
leaq 0xf4a6e(%rip), %rax     # 0x160f30
leaq 0x48(%rsp), %rdi
movq %rax, (%rdi)
callq 0x6207e
addq $0x68, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
jmp 0x6c5d4
movq %rax, %r15
leaq 0x8(%rsp), %rdi
callq 0x59200
jmp 0x6c4f5
movq %rax, %r15
movl $0x5b8, %esi            # imm = 0x5B8
jmp 0x6c551
jmp 0x6c50d
jmp 0x6c5d4
movq %rax, %r15
movl $0x768, %esi            # imm = 0x768
jmp 0x6c551
movq %rax, %r15
leaq 0x8(%rsp), %rdi
callq 0x56720
jmp 0x6c5d7
jmp 0x6c521
movq %rax, %r15
leaq 0x8(%rsp), %rdi
callq 0x59200
jmp 0x6c533
movq %rax, %r15
movl $0x5c0, %esi            # imm = 0x5C0
jmp 0x6c551
movq %rax, %r15
leaq 0x8(%rsp), %rdi
callq 0x59148
jmp 0x6c54c
movq %rax, %r15
movl $0x5c8, %esi            # imm = 0x5C8
movq %r12, %rdi
callq 0x55480
jmp 0x6c5d7
jmp 0x6c5cf
jmp 0x6c55f
movq %rax, %r15
leaq 0x8(%rsp), %rdi
callq 0x59200
jmp 0x6c571
movq %rax, %r15
movl $0x5d8, %esi            # imm = 0x5D8
jmp 0x6c5be
jmp 0x6c580
jmp 0x6c580
jmp 0x6c59b
jmp 0x6c580
movq %rax, %r15
leaq 0x8(%rsp), %rdi
callq 0x59200
jmp 0x6c59e
jmp 0x6c59b
movq %rax, %r15
movl $0x5f8, %esi            # imm = 0x5F8
jmp 0x6c5be
movq %rax, %r15
movl $0x5c8, %esi            # imm = 0x5C8
jmp 0x6c5be
jmp 0x6c5a7
movq %rax, %r15
leaq 0x8(%rsp), %rdi
callq 0x59200
jmp 0x6c5b9
movq %rax, %r15
movl $0x6d8, %esi            # imm = 0x6D8
movq %r12, %rdi
callq 0x55480
jmp 0x6c5eb
movq %rax, %r15
jmp 0x6c5f3
jmp 0x6c5d4
movq %rax, %r15
jmp 0x6c5eb
movq %rax, %r15
leaq 0xf4952(%rip), %rax     # 0x160f30
leaq 0x48(%rsp), %rdi
movq %rax, (%rdi)
callq 0x6207e
movq %r14, %rdi
callq 0x63e08
movq %rbx, %rdi
callq 0x55b00
movq %r15, %rdi
callq 0x57090
nop