Page Menu
Home
GnuPG
Search
Configure Global Search
Log In
Files
F35156008
AphrontTwoColumnView.php
No One
Temporary
Actions
Download File
Edit File
Delete File
View Transforms
Subscribe
Mute Notifications
Award Token
Size
1 KB
Subscribers
None
AphrontTwoColumnView.php
View Options
<?php
final
class
AphrontTwoColumnView
extends
AphrontView
{
private
$mainColumn
;
private
$sideColumn
;
private
$centered
=
false
;
private
$padding
=
true
;
public
function
setMainColumn
(
$main
)
{
$this
->
mainColumn
=
$main
;
return
$this
;
}
public
function
setSideColumn
(
$side
)
{
$this
->
sideColumn
=
$side
;
return
$this
;
}
public
function
setCentered
(
$centered
)
{
$this
->
centered
=
$centered
;
return
$this
;
}
public
function
setNoPadding
(
$padding
)
{
$this
->
padding
=
$padding
;
return
$this
;
}
public
function
render
()
{
require_celerity_resource
(
'aphront-two-column-view-css'
);
$main
=
phutil_tag
(
'div'
,
array
(
'class'
=>
'aphront-main-column'
,
),
$this
->
mainColumn
);
$side
=
phutil_tag
(
'div'
,
array
(
'class'
=>
'aphront-side-column'
,
),
$this
->
sideColumn
);
$classes
=
array
(
'aphront-two-column'
);
if
(
$this
->
centered
)
{
$classes
=
array
(
'aphront-two-column-centered'
);
}
if
(
$this
->
padding
)
{
$classes
[]
=
'aphront-two-column-padded'
;
}
return
phutil_tag
(
'div'
,
array
(
'class'
=>
implode
(
' '
,
$classes
),
),
array
(
$main
,
$side
,
));
}
}
File Metadata
Details
Attached
Mime Type
text/x-php
Expires
Mon, Feb 2, 8:11 AM (18 h, 6 m)
Storage Engine
local-disk
Storage Format
Raw Data
Storage Handle
4a/33/ce11bcb596543db2f500dd8f6e9b
Attached To
rPHAB Phabricator
Event Timeline
Log In to Comment