
206 N.W.2d 51 (1973)
190 Neb. 87
Barbara C. BENSON, Appellant,
v.
Hugo L. BENSON, Appellee.
No. 38709.
Supreme Court of Nebraska.
April 6, 1973.
*52 Philip M. Kneifl, Kneifl, Kneifl, Byrne & Homan, Omaha, for appellant.
J. William Gallup, Henry C. Rosenthal, Jr., Omaha, for appellee.
Heard before WHITE, C. J., and SPENCER, BOSLAUGH, SMITH, McCOWN, NEWTON, and CLINTON, JJ.
CLINTON, Justice.
This appeal arises out of a hearing on a contempt citation in the course of divorce proceedings. The plaintiff wife was divorced from the defendant husband on August 21, 1968. She was awarded custody of the two minor children, "subject to the defendant's right of reasonable visitation." Almost immediately the parties had difficulty in connection with the visitation rights and the court was required to spell out these rights in detail. Various orders were entered from time to time, but the conflict was not resolved and the two district judges before whom the matters were heard became much concerned about the effect the power struggle between the parents was having upon the two daughters who were aged 8 and 6 at the time of the divorce.
On June 22, 1971, the court ordered an independent investigation under the provisions of sections 42-307 and 42-808, R.R.S. 1943. The plaintiff had at some point, without permission of the court, removed the children from the jurisdiction and established her home with her second husband in Council Bluffs, Iowa. Following such investigation and upon notice and hearing in which both parties participated personally and through counsel, the court on February 17, 1972, made findings and order including the following: "That the rights of the children to know and to appreciate and to have the filial affection and security of a natural father and to have his love and attention dictate a schedule of visitation so that both the children and the father may have the opportunity to establish and maintain a relationship as much in keeping with the rights of each as are possible under the circumstances. That the conduct of the Plaintiff in willfully removing the children from the State of Nebraska indicates that no ratification should be made of her willful conduct and that no leave of Court be granted to now do what she has already done, that is attempt to remove the children from the jurisdiction of this Court; that, however, since a residence or domicile has been established by the Plaintiff and her now husband, provisions should be made so that the children might reside with her on a temporary basis." The court ordered:
*53 ". . . That the custody of the minor children, Elizabeth Lynn Benson and Laurie Ellen Benson, be and hereby is taken in this Court, until further Order of the Court;. . .." It further granted the plaintiff "responsibility of the care of said children and the right to possession of said children under the conditions and limitations" herein imposed. It granted permission for the children to reside with the plaintiff in Pottawattamie County, Iowa, "conditioned, however, upon it being clearly understood that this authorization shall in no way deprive this Court of jurisdiction of said children." It then spelled out in detail the visitation rights of the defendant, which details included an order directing the plaintiff to deliver the children to the defendant for specified periodic visitations and for the defendant to return the children to the plaintiff's residence at the designated hour at the end of the visitation. It further ordered: ". . . that the Defendant shall have possession of said children during one of the Summer months (June, July or August) of each Summer."
Nonetheless, trouble continued. The defendant filed an application to have possession changed to him and also caused to be issued an order to show cause why the plaintiff should not be cited for contempt. Both matters were noticed for hearing at the same time. At the beginning of the hearing the court announced that only the contempt matter would be heard at that time. The hearing then proceeded on that basis. At the end of the hearing the court found the plaintiff guilty of contempt and modified slightly the provisions of the periodic visitations and also granted the defendant possession of the children from 6 o'clock p. m., Friday, June 9, 1972, to 7 o'clock p. m. August 6, 1972.
The plaintiff on this appeal asserts that the court had no jurisdiction to enter the order enlarging the vacation period possession of the defendant because that was not the matter being heard. The plaintiff relies upon Erpelding v. Erpelding, 176 Neb. 266, 125 N.W.2d 688; and Morehouse v. Morehouse, 159 Neb. 255, 66 N.W.2d 579, and contends that under the circumstances there was the equivalent of lack of notice and opportunity to be heard insofar as the modification of the order of February 17, 1972, is concerned. The plaintiff might also have cited Vasa v. Vasa, 165 Neb. 69, 84 N.W.2d 185.
The cited cases are not in point. Here the court had, by its order of February 17, 1972, expressly retained custody of the children in the court. This procedure has the sanction of previous practice of the district court of this state and of this court. Lueders v. Lueders, 187 Neb. 539, 192 N.W.2d 161; Hanson v. Hanson, 187 Neb. 108, 187 N.W.2d 647. Its purpose is to "facilitate judicial supervision and summary power to act swiftly in their [the children's] best interests." Lueders v. Lueders, supra. The parent having possession where the court has retained custody is in effect an agent of the court. For an analogy see Hall v. Hall, 176 Neb. 555, 126 N.W.2d 839. The record supports the conclusion that the best interests of the children were being served.
Affirmed.
