Skip to content

Commit

Permalink
Browse files Browse the repository at this point in the history
Renamed using version number
  • Loading branch information
joshuanathanson committed Aug 8, 2013
1 parent 15c2394 commit eaec340
Show file tree
Hide file tree
Showing 4 changed files with 19 additions and 31 deletions.
20 changes: 11 additions & 9 deletions jquery.clockpick.css → jquery.clockpick.1.2.9.css
@@ -1,7 +1,7 @@
#CP_hourcont {
padding: 0px;
position:absolute;
border:1px dashed #bbbbbb;
border:1px solid #dddddd;
background-color:#dddddd;
display:none;
}
Expand All @@ -10,8 +10,8 @@ display:none;
background-color:#dddddd;
padding: 0px;
position:absolute;
width:45px;
border: 1px dashed #cccccc;
width:50px;
border: 1px solid #dddddd;
display:none;
}

Expand All @@ -20,19 +20,21 @@ float:left;
}

.CP_hour {
padding:1px;
color:white;
padding:3px;
font-family: Arial, Helvetica, sans-serif;
font-size:9px;
font-size:10px;
white-space:nowrap;
cursor:pointer;
width:35px;
margin:1px;
background-color:#eeeeee;
background-color:#999999;
}

.CP_minute {
padding:1px;
background-color:#eeeeee;
color:white;
padding:3px;
background-color:#aaaaaa;
font-family: Arial, Helvetica, sans-serif;
font-size:9px;
white-space:nowrap;
Expand All @@ -42,5 +44,5 @@ margin:1px;
}

.CP_over {
background-color:#ffffff;
background-color:#666666;
}
28 changes: 7 additions & 21 deletions jquery.clockpick.js → jquery.clockpick.1.2.9.js
Expand Up @@ -3,7 +3,6 @@ ClockPick, by Josh Nathanson
Version 1.2.9
Timepicker plugin for jQuery
See copyright at end of file
Complete documentation at http://www.jnathanson.com/index.cfm?page=jquery/clockpick/ClockPick
name clockpick
type jQuery
param options hash object containing config options
Expand All @@ -17,7 +16,6 @@ param options[layout] string set div layout to vertic
('vertical','horizontal')
param options[valuefield] string field to insert time value, if not same as click field
(name of input field)
param options[useBgiframe] bool set true if using bgIframe plugin
param options[hoursopacity] float set opacity of hours container
param options[minutesopacity] float set opacity of minutes container
param callback function callback function - gets passed back the time value as a
Expand All @@ -35,7 +33,6 @@ jQuery.fn.clockpick = function(options, callback) {
event : 'click',
layout : 'vertical',
valuefield : null,
useBgiframe : false,
hoursopacity : 1,
minutesopacity : 1
};
Expand Down Expand Up @@ -73,7 +70,7 @@ jQuery.fn.clockpick = function(options, callback) {
// add class "CP" for mouseout recognition, although there is only
// one hourcont on the screen at a time
var $hourcont = jQuery("<div id='CP_hourcont' class='CP' />").appendTo( $body );
!settings.useBgiframe ? $hourcont.css("opacity",settings.hoursopacity) : null;
$hourcont.css("opacity",settings.hoursopacity);
binder( $hourcont );

var $hourcol1 = jQuery("<div class='CP_hourcol' id='hourcol1' />").appendTo( $body );
Expand All @@ -82,7 +79,7 @@ jQuery.fn.clockpick = function(options, callback) {
// if showminutes, append minutes cont to body
if (settings.showminutes) {
var $mc = jQuery("<div id='CP_minutecont' class='CP' />").appendTo( $body );
!settings.useBgiframe ? $mc.css("opacity",settings.minutesopacity) : null;
$mc.css("opacity",settings.minutesopacity)
binder($mc);
}
if ( !v ) {
Expand Down Expand Up @@ -121,9 +118,11 @@ jQuery.fn.clockpick = function(options, callback) {
if ( settings.military && h < 10 ) {
displayhours = '0' + displayhours;
}
if ( settings.military ) {
displayhours += ':00';
}
var $hd = jQuery("<div class='CP_hour' id='hr_" + h + "_" + c + "'>" + displayhours + set_tt(h) + "</div>");
// shrink width a bit if military
if (settings.military) { $hd.width(20); }
binder($hd);
if (!v) {
$hd.css("float","left");
Expand Down Expand Up @@ -186,10 +185,7 @@ jQuery.fn.clockpick = function(options, callback) {
else {
$self.after($hourcont);
}
$hourcont.slideDown('fast');

if ( settings.useBgiframe )
bgi( $hourcont );
$hourcont.slideDown('fast');
}

function rectify($obj) {
Expand Down Expand Up @@ -217,13 +213,6 @@ jQuery.fn.clockpick = function(options, callback) {
}
}

function bgi( ob ) {
if ( typeof jQuery.fn.bgIframe == 'function' )
ob.bgIframe();
else
alert('bgIframe plugin not loaded.');
}

function binder($obj) {
// all the binding is done here
// event handlers have been abstracted out,
Expand Down Expand Up @@ -323,9 +312,6 @@ jQuery.fn.clockpick = function(options, callback) {
$mc.css("left",l+'px').css("top",t+'px');
rectify( $mc );
$mc.show();

if ( settings.useBgiframe )
bgi( $mc );
}
return false;
}
Expand Down Expand Up @@ -561,7 +547,7 @@ jQuery.fn.clockpick = function(options, callback) {

/*
+-----------------------------------------------------------------------+
| Copyright (c) 2007-2010 Josh Nathanson |
| Copyright (c) 2007-2013 Josh Nathanson |
| All rights reserved. |
| |
| Redistribution and use in source and binary forms, with or without |
Expand Down
1 change: 1 addition & 0 deletions jquery.clockpick.1.2.9.min.js

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

1 change: 0 additions & 1 deletion jquery.clockpick.min.js

This file was deleted.

0 comments on commit eaec340

Please sign in to comment.