Gauss derived a new condition for the angle of contact of the capillary surface with the surface of a solid, that was a consequence of his new variational approach to the theory. Before him Laplace and Poisson derived the capillarity theory from hypotheses about molecular forces, which were little known at the time, and so open to criticisms, by Young among others. Even worse, Poisson's expressions for capillary pressure in terms of molecular forces were different from those of Laplace, while there was no difference in observable predictions. Arago called it a "mathematical scandal", it was an early example of empirical underdetermination of theories. See Grattan-Guinness's Companion Encyclopedia of the History and Philosophy of the Mathematical Sciences, vol 2.
In Principia Generalia Theoriae Figurae Fluidorum in Statu Aequilibrii (1830) Gauss came up with an "energetist" approach that was far less sensitive to hypotheses about specifics of molecular forces. According to Britannica:"The principle which he adopted is that of virtual velocities, a principle which under his hands was gradually transforming itself into what is now known as the principle of the conservation of energy. Instead of calculating the direction and magnitude of the resultant force on each particle arising from the action of neighbouring particles, he formed a single expression which is the aggregate of all the potentials arising from the mutual action between pairs of particles. This expression has been called the force-function. With its sign reversed it is now called the potential energy of the system... The condition of equilibrium is that this expression (which we may for the sake of distinctness call the potential energy) shall be a minimum. This condition when worked out gives not only the equation of the free surface in the form already established by Laplace, but the conditions of the angle of contact of this surface with the surface of a solid. Gauss thus supplied the principal defect in the great work of Laplace".
The energetist method was developed by Dupre (1869) and Gibbs (1878) completely purged it of any molecular notions leaving only thermodynamic ones. While it was useful in reducing dependence of phenomenological theories on molecular hypotheses at the end of 19th century Mach and Ostwald took it too far under the name of "energetics". They turned energetics into a positivist alternative to atomism in general, and Boltzmann's kinetic theory in particular, which they saw as metaphysical speculations. It was largely abandoned (except by Mach) after Einstein and Smoluchowski developed a theory of Brownian motion based on kinetic theory around 1905, which was experimentally confirmed. See Deltete's Helm and Boltzmann: Energetics at the Lübeck Naturforscherversammlung.