forked from Arpit007/Photography
-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathScript.js
More file actions
114 lines (104 loc) · 2.83 KB
/
Script.js
File metadata and controls
114 lines (104 loc) · 2.83 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
var SelectionColor="rgb(254, 254, 254)";
function Loaded()
{
HomeClick();
}
function openInNewTab(url)
{
var win = window.open(url, '_blank');
win.focus();
}
function OpenNavBar()
{
var sideBar=document.getElementById("Nav_Bar");
if(sideBar.style.left=="-15%" || sideBar.style.left=="")
{
sideBar.style.left=0;
}
else
{
sideBar.style.left="-15%";
}
}
function ResetNavButtons()
{
for(var x=1;x<=4;x++)
{
var btn=document.getElementById("Nav_Button_"+x);
if(btn.style.color==SelectionColor)
continue;
btn.style.backgroundColor="rgba(25, 25, 25, 0)";
}
}
function ResetButtons()
{
for(var x=1;x<=4;x++)
{
var btn=document.getElementById("Menu_Button_"+x);
btn.style.borderBottomWidth="0px";
btn.style.color="#ffffff";
btn=document.getElementById("Nav_Button_"+x);
btn.style.color="#ffffff";
}
ResetNavButtons();
}
function HomeClick()
{
var btn=document.getElementById("Menu_Button_1")
if(btn.style.color==SelectionColor)
return;
ResetButtons();;
btn.style.borderBottomWidth="3px";
btn.style.color=SelectionColor;
btn=document.getElementById("Nav_Button_1");
btn.style.color=SelectionColor;
btn.style.backgroundColor="rgba(25, 25, 25, 0.5)";
document.getElementById('Main_Content').src="Home.html";
}
function GalleryClick()
{
var btn=document.getElementById("Menu_Button_2")
if(btn.style.color==SelectionColor)
return;
ResetButtons();
btn.style.borderBottomWidth="3px";
btn.style.color=SelectionColor;
btn=document.getElementById("Nav_Button_2");
btn.style.color=SelectionColor;
btn.style.backgroundColor="rgba(25, 25, 25, 0.5)";
document.getElementById('Main_Content').src="Gallery.html";
}
function AboutClick()
{
var btn=document.getElementById("Menu_Button_3")
if(btn.style.color==SelectionColor)
return;
document
ResetButtons();
btn.style.borderBottomWidth="3px";
btn.style.color=SelectionColor;
btn=document.getElementById("Nav_Button_3");
btn.style.color=SelectionColor;
btn.style.backgroundColor="rgba(25, 25, 25, 0.5)";
document.getElementById('Main_Content').src="About.html";
}
function FeedbackClick()
{
var btn=document.getElementById("Menu_Button_4")
if(btn.style.color==SelectionColor)
return;
ResetButtons();
btn.style.borderBottomWidth="3px";
btn.style.color=SelectionColor;
btn=document.getElementById("Nav_Button_4");
btn.style.color=SelectionColor;
btn.style.backgroundColor="rgba(25, 25, 25, 0.5)";
document.getElementById('Main_Content').src="Feedback.html";
}
function NavMouseOver(x)
{
ResetNavButtons();
if(x=='null')
return;
document.getElementById(x).style.backgroundColor="rgba(25, 25, 25, 0.4)";
}